Part Number Hot Search : 
710W0002 744107 PG20N06S UPA832 HER30 PIC18F2 SK331 DTV1500
Product Description
Full Text Search
 

To Download SAA7146AH Datasheet File

  If you can't view the Datasheet, Please click here to try to view without PDF Reader .  
 
 


  Datasheet File OCR Text:
  d a t a sh eet product speci?cation file under integrated circuits, ic22 1998 apr 09 integrated circuits saa7146a multimedia bridge, high performance scaler and pci circuit (spci)
1998 apr 09 2 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a contents 1 features 1.1 video processing 1.2 audio processing 1.3 scaling 1.4 interfacing 1.5 general 2 general description 3 quick reference data 4 ordering information 5 block diagram 6 pinning 7 functional description 7.1 general 7.2 pci interface 7.3 main control 7.4 register programming sequencer (rps) 7.5 status and interrupts 7.6 general purpose inputs/outputs (gpio) 7.7 event counter 7.8 video processing 7.9 high performance scaler (hps) 7.10 binary ratio scaler (brs) 7.11 video data formats on the pci-bus 7.12 scaler register 7.13 scaler event description 7.14 clipping 7.15 data expansion bus interface (debi) 7.16 audio interface 7.17 i 2 c-bus interface 7.18 saa7146a register tables 8 boundary scan test 8.1 initialization of boundary scan circuit 8.2 device identification codes 9 electrical operating conditions 10 characteristics 11 application example 12 package outlines 13 soldering 13.1 introduction 13.2 reflow soldering 13.3 wave soldering 13.4 repairing soldered joints 14 definitions 15 life support applications 16 purchase of philips i 2 c components
1998 apr 09 3 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 1 features 1.1 video processing full size, full speed video delivery to and from the frame buffer or virtual system memory enables various processing possibilities for any external pci device full bandwidth pci-bus master write and read (up to 132 mbytes/s) virtual memory support (4 mbytes per dma channel) processing of maximum 4095 active samples per line and maximum 4095 lines per frame vanity picture (mirror) for video phone and video conferencing applications video flip (upside down picture) colour space conversion with gamma correction for different kinds of displays chroma key generation and utilization pixel dithering for low resolution video output formats brightness, contrast and saturation control video and vertical blanking interval (vbi) synchronized programming of internal registers with register programming sequencer (rps), ability to control two asynchronous data streams simultaneously memory management unit (mmu) supports virtual demand paging memory management (windows, unix, etc.) rectangular clipping of frame buffer areas minimizes pci-bus load random shape mask clipping protects selectable areas of frame buffer 3 128 dword video fifo with overflow detection and graceful recovery. 1.2 audio processing time slot list (tsl) processing for flexible control of audio frames up to 256 bits on 2 asynchronous bidirectional digital audio interfaces simultaneously (4 dma channels) video synchronous audio capture, e.g. for sound cards various synchronization modes to support i 2 s and other different audio and dsp data formats audio input level monitoring enables peak control via software programmable bit clock generation for master and slave applications. 1.3 scaling scaling of video pictures down to randomly sized windows (vertical down to 1 : 1024; horizontal down to 1 : 256) high performance scaler (hps) offers two-dimensional, phase correct data processing for improved signal quality of scaled video data, especially for compression applications horizontal and vertical fir filters with up to 65 taps horizontal upscaling (zoom) supports e.g. ccir to square pixel conversion additional binary ratio scaler (brs) supports cif and qcif formats, especially for video phone and video conferencing. 1.4 interfacing dual d1 (8-bit, ccir 656) video i/o interface dmsd2 compatible (16-bit yuv) video input interface supports various packed (pixel dithering) and planar video output formats data expansion bus interface (debi) for interfacing with e.g. mpeg or jpeg decoders with intel (isa like) and motorola (68000 like) protocol style, capability for immediate and block mode (dma) transfers with up to 23 mbytes/s peak data rate 5 digital audio i/o ports 4 independent user configurable general purpose i/o ports (gpi/o) for interrupt and status processing pci interface (release 2.1) i 2 c-bus interface (bus master).
1998 apr 09 4 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 1.5 general subsystem (board) vendor id support for board identification via software driver internal arbitration control diagnostic support and event analysis programmable vertical blanking interval (vbi) data region for e.g. to support intercast, teletext, closed caption and similar applications 3.3 v supply enables reduced power consumption, 5 v tolerant i/os for 5 v pci signalling environment. 2 general description the saa7146a, multimedia pci-bridge, is a highly integrated circuit for desktop video (dtv) applications. the device provides a number of interface ports that enable a wide variety of video and audio ics to be connected to the pci-bus thus supporting a number of video applications in a pc. one example of the application capabilities is shown in fig.49. figure 1 shows the various interface ports and the main internal function blocks. 3 quick reference data 4 ordering information symbol parameter min. typ. max. unit v ddd digital supply voltage 3.0 3.3 3.6 v i ddd(tot) total digital supply current - 400 - ma v i ;v o data input/output levels ttl compatible f llc llc input clock frequency -- 32 mhz f pci pci input clock frequency -- 33 mhz f i2s i 2 s input clock frequency -- 12.5 mhz t amb operating ambient temperature 0 - 70 c type number package name description version SAA7146AH qfp160 plastic quad ?at package; 160 leads (lead length 1.95 mm); body 28 28 3.4 mm; high stand-off height sot322-1 SAA7146AHz sqfp208 plastic shrink quad ?at package; 208 leads (lead length 1.3 mm); body 28 28 3.4 mm sot316-1
1998 apr 09 5 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a this text is here in white to force landscape pages to be rotated correctly when browsing through the pdf in the acrobat reader .this text is here in _ white to force landscape pages to be rotated correctly when browsing through the pdf in the acrobat reader.this text is here in this text is here in white to force landscape pages to be rotated correctly when browsing through the pdf in the acrobat reader. white to force land scape pages to be ... 5 block diagram o k, full pagewidth mhb044 gpio port i/o rps saa7146a task 1 colour space cv. gamma correction pixel-formatter/dither task 2 event manager i 2 c-bus master control data i 2 c-bus i 2 s 1 -bus i 2 s 2 -bus debi port intel/ motorola debi fifo audio fifo pci interface pci bus dma and internal arbitration controller mmu tsl audio input/output audio input/output video fifo1 video fifo2 clipping unit binary ratio scaler video fifo3 8-bit d1 input/output 8-bit d1 input/output real time video interface dual d1 or 16-bit yuv 16-bit yuv in high performance scaler h-filter/scaler v-filter/scaler yuv/rgb yuv yuv yuv video-flip/mirror fig.1 block diagram.
1998 apr 09 6 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 6 pinning pin description for qfp160 symbol pin status description d1_a0 1 i/o bidirectional digital ccir 656 d1 port a bit 0 d1_a1 2 i/o bidirectional digital ccir 656 d1 port a bit 1 d1_a2 3 i/o bidirectional digital ccir 656 d1 port a bit 2 d1_a3 4 i/o bidirectional digital ccir 656 d1 port a bit 3 v ddd1 5 p digital supply voltage 1 (3.3 v) v ssd1 6 p digital ground 1 d1_a4 7 i/o bidirectional digital ccir 656 d1 port a bit 4 d1_a5 8 i/o bidirectional digital ccir 656 d1 port a bit 5 d1_a6 9 i/o bidirectional digital ccir 656 d1 port a bit 6 d1_a7 10 i/o bidirectional digital ccir 656 d1 port a bit 7 vs_a 11 i/o bidirectional vertical sync signal port a hs_a 12 i/o bidirectional horizontal sync signal port a llc_a 13 i/o bidirectional line-locked system clock port a pxq_a 14 i/o bidirectional pixel quali?er signal to mark valid pixels port a; note 1 v ddd2 15 p digital supply voltage 2 (3.3 v) v ssd2 16 p digital ground 2 trst 17 i test reset input (jtag pin must be set low for normal operation) tms 18 i test mode select input (jtag pin must be ?oating or set to high during normal operation) tclk 19 i test clock input (jtag pin should be set low during normal operation) tdo 20 o test data output (jtag pin not active during normal operation) tdi 21 i test data input (jtag pin must be ?oating or set to high during normal operation) v ddd3 22 p digital supply voltage 3 (3.3 v) v ssd3 23 p digital ground 3 inta# 24 o pci interrupt line output (active low) rst 25 i pci global reset input (active low) clk 26 i pci clock input gnt# 27 i bus grant input signal, pci arbitration signal (active low) req# 28 o bus request output signal, pci arbitration signal (active low) v ddd4 29 p digital supply voltage 4 (3.3 v) v ssd4 30 p digital ground 4 ad pci31 31 i/o bidirectional pci multiplexed address/data bit 31 ad pci30 32 i/o bidirectional pci multiplexed address/data bit 30 ad pci29 33 i/o bidirectional pci multiplexed address/data bit 29 ad pci28 34 i/o bidirectional pci multiplexed address/data bit 28 v ddd5 35 p digital supply voltage 5 (3.3 v) v ssd5 36 p digital ground 5 ad pci27 37 i/o bidirectional pci multiplexed address/data bit 27
1998 apr 09 7 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a ad pci26 38 i/o bidirectional pci multiplexed address/data bit 26 ad pci25 39 i/o bidirectional pci multiplexed address/data bit 25 ad pci24 40 i/o bidirectional pci multiplexed address/data bit 24 c/be# [3] 41 i/o bidirectional pci multiplexed bus command and byte enable 3 (active low) idsel 42 i pci initialization device select signal input ad pci23 43 i/o bidirectional pci multiplexed address/data bit 23 ad pci22 44 i/o bidirectional pci multiplexed address/data bit 22 ad pci21 45 i/o bidirectional pci multiplexed address/data bit 21 ad pci20 46 i/o bidirectional pci multiplexed address/data bit 20 v ddd6 47 p digital supply voltage 6 (3.3 v) v ssd6 48 p digital ground 6 ad pci19 49 i/o bidirectional pci multiplexed address/data bit 19 ad pci18 50 i/o bidirectional pci multiplexed address/data bit 18 ad pci17 51 i/o bidirectional pci multiplexed address/data bit 17 ad pci16 52 i/o bidirectional pci multiplexed address/data bit 16 v ddd7 53 p digital supply voltage 7 (3.3 v) v ssd7 54 p digital ground 7 c/be# [2] 55 i/o bidirectional pci multiplexed bus command and byte enable 2 (active low) frame# 56 i/o bidirectional pci cycle frame signal (active low) irdy# 57 i/o bidirectional pci initiator ready signal (active low) trdy# 58 i/o bidirectional pci target ready signal (active low) devsel# 59 i/o bidirectional pci device select signal (active low) stop# 60 i/o bidirectional pci stop signal (active low) perr# 61 o pci parity error signal output (active low) par 62 i/o bidirectional pci parity signal c/be# [1] 63 i/o bidirectional pci-bus command and byte enable 1 (active low) v ddd8 64 p digital supply voltage 8 (3.3 v) v ssd8 65 p digital ground 8 ad pci15 66 i/o bidirectional pci multiplexed address/data bit 15 ad pci14 67 i/o bidirectional pci multiplexed address/data bit 14 ad pci13 68 i/o bidirectional pci multiplexed address/data bit 13 ad pci12 69 i/o bidirectional pci multiplexed address/data bit 12 v ddd9 70 p digital supply voltage 9 (3.3 v) v ssd9 71 p digital ground 9 ad pci11 72 i/o bidirectional pci multiplexed address/data bit 11 ad pci10 73 i/o bidirectional pci multiplexed address/data bit 10 ad pci9 74 i/o bidirectional pci multiplexed address/data bit 9 ad pci8 75 i/o bidirectional pci multiplexed address/data bit 8 v ddd10 76 p digital supply voltage 10 (3.3 v) v ssd10 77 p digital ground 10 c/be# [0] 78 i/o bidirectional pci multiplexed bus command and byte enable 0 (active low) symbol pin status description
1998 apr 09 8 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a ad pci7 79 i/o bidirectional pci multiplexed address/data bit 7 ad pci6 80 i/o bidirectional pci multiplexed address/data bit 6 v ssd11 81 p digital ground 11 ad pci5 82 i/o bidirectional pci multiplexed address/data bit 5 ad pci4 83 i/o bidirectional pci multiplexed address/data bit 4 ad pci3 84 i/o bidirectional pci multiplexed address/data bit 3 ad pci2 85 i/o bidirectional pci multiplexed address/data bit 2 v ddd11 86 p digital supply voltage 11 (3.3 v) v ssd12 87 p digital ground 12 ad pci1 88 i/o bidirectional pci multiplexed address/data bit 1 ad pci0 89 i/o bidirectional pci multiplexed address/data bit 0 v ddd12 90 p digital supply voltage 12 (3.3 v) v ssd13 91 p digital ground 13 ad15 92 i/o bidirectional debi multiplexed address data line bit 15 ad14 93 i/o bidirectional debi multiplexed address data line bit 14 ad13 94 i/o bidirectional debi multiplexed address data line bit 13 ad12 95 i/o bidirectional debi multiplexed address data line bit 12 v ddd13 96 p digital supply voltage 13 (3.3 v) v ssd14 97 p digital ground 14 ad11 98 i/o bidirectional debi multiplexed address data line bit 11 ad10 99 i/o bidirectional debi multiplexed address data line bit 10 ad9 100 i/o bidirectional debi multiplexed address data line bit 9 ad8 101 i/o bidirectional debi multiplexed address data line bit 8 v ddd14 102 p digital supply voltage 14 (3.3 v) v ssd15 103 p digital ground 15 rwn_sbhe 104 o debi data transfer control signal output (read write not/system byte high enable) as_ale 105 o debi address strobe and address latch enable output lds_rdn 106 o lower data strobe/read not output uds_wrn 107 o upper data strobe/write not output dtack_rdy 108 i debi data transfer acknowledge or ready input v ddd15 109 p digital supply voltage 15 (3.3 v) v ssd16 110 p digital ground 16 ad0 111 i/o bidirectional debi multiplexed address data line bit 0 ad1 112 i/o bidirectional debi multiplexed address data line bit 1 ad2 113 i/o bidirectional debi multiplexed address data line bit 2 ad3 114 i/o bidirectional debi multiplexed address data line bit 3 v ddd16 115 p digital supply voltage 16 (3.3 v) v ssd17 116 p digital ground 17 ad4 117 i/o bidirectional debi multiplexed address data line bit 4 ad5 118 i/o bidirectional debi multiplexed address data line bit 5 symbol pin status description
1998 apr 09 9 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a ad6 119 i/o bidirectional debi multiplexed address data line bit 6 ad7 120 i/o bidirectional debi multiplexed address data line bit 7 ws0 121 i/o bidirectional word select signal for audio interface a1 sd0 122 i/o bidirectional serial data for audio interface a1 bclk1 123 i/o bidirectional bit clock for audio interface a1 ws1 124 o word select output signal for audio interface a1/a2 sd1 125 i/o bidirectional serial data for audio interface a1/a2 ws2 126 o word select output signal for audio interface a1/a2 sd2 127 i/o bidirectional serial data for audio interface a1/a2 v ddd17 128 p digital supply voltage 17 (3.3 v) v ssd18 129 p digital ground 18 ws3 130 o word select output signal for audio interface a1/a2 sd3 131 i/o bidirectional serial data for audio interface a1/a2 bclk2 132 i/o bidirectional bit clock for audio interface a2 ws4 133 i/o bidirectional word select signal for audio interface a2 sd4 134 i/o bidirectional serial data for audio interface a2 aclk 135 i audio reference clock input signal scl 136 i/o bidirectional i 2 c-bus clock line sda 137 i/o bidirectional i 2 c-bus data line v ddd18 138 p digital supply voltage 18 (3.3 v) v ddi2c 139 i i 2 c-bus voltage sense input; see note 3 of characteristics v ssd19 140 p digital ground 19 gpio3 141 i/o general purpose i/o signal 3 gpio2 142 i/o general purpose i/o signal 2 gpio1 143 i/o general purpose i/o signal 1 gpio0 144 i/o general purpose i/o signal 0 d1_b0 145 i/o bidirectional digital ccir 656 d1 port b bit 0 d1_b1 146 i/o bidirectional digital ccir 656 d1 port b bit 1 d1_b2 147 i/o bidirectional digital ccir 656 d1 port b bit 2 d1_b3 148 i/o bidirectional digital ccir 656 d1 port b bit 3 v ddd19 149 p digital supply voltage 19 (3.3 v) v ssd20 150 p digital ground 20 d1_b4 151 i/o bidirectional digital ccir 656 d1 port b bit 4 d1_b5 152 i/o bidirectional digital ccir 656 d1 port b bit 5 d1_b6 153 i/o bidirectional digital ccir 656 d1 port b bit 6 d1_b7 154 i/o bidirectional digital ccir 656 d1 port b bit 7 v ddd20 155 p digital supply voltage 20 (3.3 v) v ssd21 156 p digital ground 21 llc_b 157 i/o bidirectional line-locked system clock port b vs_b 158 i/o bidirectional vertical sync signal port b symbol pin status description
1998 apr 09 10 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a notes 1. for continuous ccir 656 format at the d1_a port this pin must be set high. 2. for continuous ccir 656 format at the d1_b port this pin must be set high. hs_b 159 i/o bidirectional horizontal sync signal port b pxq_b 160 i/o bidirectional pixel quali?er signal to mark valid pixels port b; note 2 symbol pin status description fig.2 pin configuration SAA7146AH (qfp160). handbook, halfpage SAA7146AH 1 160 121 41 80 40 120 81 mhb045
1998 apr 09 11 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a pin description for sqfp208 symbol pin status description v ssd0 1 p digital ground 0 d1_a0 2 i/o bidirectional digital ccir 656 d1 port a bit 0 d1_a1 3 i/o bidirectional digital ccir 656 d1 port a bit 1 d1_a2 4 i/o bidirectional digital ccir 656 d1 port a bit 2 d1_a3 5 i/o bidirectional digital ccir 656 d1 port a bit 3 v ddd1 6 p digital supply voltage 1 (3.3 v) n.c. 7 - reserved pin; not connected internally v ssd1 8 p digital ground 1 d1_a4 9 i/o bidirectional digital ccir 656 d1 port a bit 4 d1_a5 10 i/o bidirectional digital ccir 656 d1 port a bit 5 d1_a6 11 i/o bidirectional digital ccir 656 d1 port a bit 6 d1_a7 12 i/o bidirectional digital ccir 656 d1 port a bit 7 v ddd2 13 p digital supply voltage 2 (3.3 v) n.c. 14 - reserved pin; not connected internally v ssd2 15 p digital ground 2 vs_a 16 i/o bidirectional vertical sync signal port a hs_a 17 i/o bidirectional horizontal sync signal port a llc_a 18 i/o bidirectional line-locked system clock port a pxq_a 19 i/o bidirectional pixel quali?er signal to mark valid pixels port a; note 1 n.c. 20 - reserved pin; do not connect v ddd3 21 p digital supply voltage 3 (3.3 v) n.c. 22 - reserved pin; not connected internally v ssd3 23 p digital ground 3 trst 24 i test reset input (jtag pin must be set low for normal operation) tms 25 i test mode select input (jtag pin must be ?oating or set to high during normal operation) tclk 26 i test clock input (jtag pin should be set low during normal operation) tdo 27 o test data output (jtag pin not active during normal operation) tdi 28 i test data input (jtag pin must be ?oating or set to high during normal operation) v ddd4 29 p digital supply voltage 4 (3.3 v) n.c. 30 - reserved pin; not connected internally v ssd4 31 p digital ground 4 inta# 32 o pci interrupt line output (active low) rst# 33 i pci global reset input (active low) clk 34 i pci clock input gnt# 35 i bus grant input signal input, pci arbitration signal (active low) req# 36 o bus request output signal output, pci arbitration signal (active low) v ddd5 37 p digital supply voltage 5 (3.3 v) n.c. 38 - reserved pin; not connected internally
1998 apr 09 12 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a v ssd5 39 p digital ground 5 ad pci31 40 i/o bidirectional pci multiplexed address/data bit 31 ad pci30 41 i/o bidirectional pci multiplexed address/data bit 30 ad pci29 42 i/o bidirectional pci multiplexed address/data bit 29 ad pci28 43 i/o bidirectional pci multiplexed address/data bit 28 v ddd6 44 p digital supply voltage 6 (3.3 v) n.c. 45 - reserved pin; not connected internally v ssd6 46 p digital ground 6 ad pci27 47 i/o bidirectional pci multiplexed address/data bit 27 ad pci26 48 i/o bidirectional pci multiplexed address/data bit 26 ad pci25 49 i/o bidirectional pci multiplexed address/data bit 25 ad pci24 50 i/o bidirectional pci multiplexed address/data bit 24 v ddd7 51 p digital supply voltage 7 (3.3 v) n.c. 52 - reserved pin; do not connect n.c. 53 - reserved pin; not connected internally v ssd7 54 p digital ground 7 c/be# [3] 55 i/o bidirectional pci multiplexed bus command and byte enable 3 (active low) idsel 56 i pci initialization device select input signal ad pci23 57 i/o bidirectional pci multiplexed address/data bit 23 ad pci22 58 i/o bidirectional pci multiplexed address/data bit 22 ad pci21 59 i/o bidirectional pci multiplexed address/data bit 21 ad pci20 60 i/o bidirectional pci multiplexed address/data bit 20 n.c. 61 - reserved pin; do not connect n.c. 62 - reserved pin; not connected internally v ssd8 63 p digital ground 8 ad pci19 64 i/o bidirectional pci multiplexed address/data bit 19 ad pci18 65 i/o bidirectional pci multiplexed address/data bit 18 ad pci17 66 i/o bidirectional pci multiplexed address/data bit 17 ad pci16 67 i/o bidirectional pci multiplexed address/data bit 16 v ddd8 68 p digital supply voltage 8 (3.3 v) n.c. 69 - reserved pin; do not connect v ssd9 70 p digital ground 9 c/be# [2] 71 i/o bidirectional pci multiplexed bus command and byte enable 2 (active low) frame# 72 i/o bidirectional pci cycle frame signal (active low) irdy# 73 i/o bidirectional pci initiator ready signal (active low) trdy# 74 i/o bidirectional pci target ready signal (active low) v ddd9 75 p digital supply voltage 9 (3.3 v) n.c. 76 - reserved pin; do not connect v ssd10 77 p digital ground 10 devsel# 78 i/o bidirectional pci device select signal (active low) symbol pin status description
1998 apr 09 13 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a stop# 79 i/o bidirectional pci stop signal (active low) perr# 80 o pci parity error output signal (active low) n.c. 81 - reserved pin; do not connect par 82 i/o bidirectional pci parity signal c/be# [1] 83 i/o bidirectional pci-bus command and byte enable 1 (active low) v ddd10 84 p digital supply voltage 10 (3.3 v) n.c. 85 - reserved pin; not connected internally v ssd11 86 p digital ground 11 ad pci15 87 i/o bidirectional pci multiplexed address/data bit 15 ad pci14 88 i/o bidirectional pci multiplexed address/data bit 14 ad pci13 89 i/o bidirectional pci multiplexed address/data bit 13 ad pci12 90 i/o bidirectional pci multiplexed address/data bit 12 v ddd11 91 p digital supply voltage 11 (3.3 v) n.c. 92 - reserved pin; not connected internally v ssd12 93 p digital ground 12 ad pci11 94 i/o bidirectional pci multiplexed address/data bit 11 ad pci10 95 i/o bidirectional pci multiplexed address/data bit 10 ad pci9 96 i/o bidirectional pci multiplexed address/data bit 9 ad pci8 97 i/o bidirectional pci multiplexed address/data bit 8 n.c. 98 - reserved pin; do not connect n.c. 99 - reserved pin; not connected internally v ssd13 100 p digital ground 13 c/be# [0] 101 i/o bidirectional pci multiplexed bus command and byte enable (active low) ad pci7 102 i/o bidirectional pci multiplexed address/data bit 7 ad pci6 103 i/o bidirectional pci multiplexed address/data bit 6 v ddd12 104 p digital supply voltage 12 (3.3 v) n.c. 105 - reserved pin; do not connect n.c. 106 - reserved pin; not connected internally v ssd14 107 p digital ground 14 ad pci5 108 i/o bidirectional pci multiplexed address/data bit 5 ad pci4 109 i/o bidirectional pci multiplexed address/data bit 4 ad pci3 110 i/o bidirectional pci multiplexed address/data bit 3 ad pci2 111 i/o bidirectional pci multiplexed address/data bit 2 v ddd13 112 p digital supply voltage 13 (3.3 v) n.c. 113 - reserved pin; not connected internally v ssd15 114 p digital ground 15 ad pci1 115 i/o bidirectional pci multiplexed address/data bit 1 ad pci0 116 i/o bidirectional pci multiplexed address/data bit 0 v ddd14 117 p digital supply voltage 14 (3.3 v) n.c. 118 - reserved pin; not connected internally v ssd16 119 p digital ground 16 symbol pin status description
1998 apr 09 14 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a ad15 120 i/o bidirectional debi multiplexed address data line bit 15 ad14 121 i/o bidirectional debi multiplexed address data line bit 14 ad13 122 i/o bidirectional debi multiplexed address data line bit 13 ad12 123 i/o bidirectional debi multiplexed address data line bit 12 v ddd15 124 p digital supply voltage 15 (3.3 v) n.c. 125 - reserved pin; not connected internally v ssd17 126 p digital ground 17 ad11 127 i/o bidirectional debi multiplexed address data line bit 11 ad10 128 i/o bidirectional debi multiplexed address data line bit 10 ad9 129 i/o bidirectional debi multiplexed address data line bit 9 ad8 130 i/o bidirectional debi multiplexed address data line bit 8 v ddd16 131 p digital supply voltage 16 (3.3 v) n.c. 132 - reserved pin; not connected internally v ssd18 133 p digital ground 18 rwn_sbhe 134 o debi data transfer control output signal (read write not/system byte high enable) as_ale 135 o debi address strobe and address latch enable output lds_rdn 136 o lower data strobe/read not output uds_wrn 137 o upper data strobe/write not output dtack_rdy 138 i debi data transfer acknowledge or ready input v ddd17 139 p digital supply voltage 17 (3.3 v) n.c. 140 - reserved pin; not connected internally v ssd19 141 p digital ground 19 ad0 142 i/o bidirectional debi multiplexed address data line bit 0 ad1 143 i/o bidirectional debi multiplexed address data line bit 1 ad2 144 i/o bidirectional debi multiplexed address data line bit 2 ad3 145 i/o bidirectional debi multiplexed address data line bit 3 v ddd18 146 p digital supply voltage 18 (3.3 v) n.c. 147 - reserved pin; not connected internally v ssd20 148 p digital ground 20 ad4 149 i/o bidirectional debi multiplexed address data line bit 4 ad5 150 i/o bidirectional debi multiplexed address data line bit 5 ad6 151 i/o bidirectional debi multiplexed address data line bit 6 ad7 152 i/o bidirectional debi multiplexed address data line bit 7 n.c. 153 - reserved pin; do not connect n.c. 154 - reserved pin; do not connect v ddd19 155 p digital supply voltage 19 (3.3 v) n.c. 156 - reserved pin; not connected internally n.c. 157 - reserved pin; do not connect v ssd21 158 p digital ground 21 ws0 159 i/o bidirectional word select signal for audio interface a1 sd0 160 i/o bidirectional serial data for audio interface a1 symbol pin status description
1998 apr 09 15 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a bclk1 161 i/o bidirectional bit clock for audio interface a1 ws1 162 o word select output signal for audio interface a1/a2 sd1 163 i/o bidirectional serial data for audio interface a1/a2 ws2 164 o word select output signal for audio interface a1/a2 sd2 165 i/o bidirectional serial data for audio interface a1/a2 v ddd20 166 p digital supply voltage 20 (3.3 v) n.c. 167 - reserved pin; not connected internally v ssd22 168 p digital ground 22 ws3 169 o word select output signal for audio interface a1/a2 sd3 170 i/o bidirectional serial data for audio interface a1/a2 bclk2 171 i/o bidirectional bit clock for audio interface a2 ws4 172 i/o bidirectional word select signal for audio interface a2 sd4 173 i/o bidirectional serial data for audio interface a2 aclk 174 i audio reference clock input signal scl 175 i/o bidirectional i 2 c-bus clock line sda 176 i/o bidirectional i 2 c-bus data line v ddd21 177 p digital supply voltage 21 (3.3 v) v ddi2c 178 i i 2 c-bus voltage sense input; see note 3 of characteristics v ssd23 179 p digital ground 23 gpio3 180 i/o general purpose i/o signal 3 gpio2 181 i/o general purpose i/o signal 2 gpio1 182 i/o general purpose i/o signal 1 gpio0 183 i/o general purpose i/o signal 0 v ddd22 184 p digital supply voltage 22 (3.3 v) n.c. 185 - reserved pin; not connected internally v ssd24 186 p digital ground 24 d1_b0 187 i/o bidirectional digital ccir 656 d1 port b bit 0 d1_b1 188 i/o bidirectional digital ccir 656 d1 port b bit 1 d1_b2 189 i/o bidirectional digital ccir 656 d1 port b bit 2 d1_b3 190 i/o bidirectional digital ccir 656 d1 port b bit 3 v ddd23 191 p digital supply voltage 23 (3.3 v) n.c. 192 - reserved pin; not connected internally v ssd25 193 p digital ground 25 d1_b4 194 i/o bidirectional digital ccir 656 d1 port b bit 4 d1_b5 195 i/o bidirectional digital ccir 656 d1 port b bit 5 d1_b6 196 i/o bidirectional digital ccir 656 d1 port b bit 6 d1_b7 197 i/o bidirectional digital ccir 656 d1 port b bit 7 v ddd24 198 p digital supply voltage 24 (3.3 v) n.c. 199 - reserved pin; not connected internally v ssd26 200 p digital ground 26 llc_b 201 i/o bidirectional line-locked system clock port b symbol pin status description
1998 apr 09 16 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a notes 1. for continuous ccir 656 format at the d1_a port this pin must be set high. 2. for continuous ccir 656 format at the d1_b port this pin must be set high. vs_b 202 i/o bidirectional vertical sync signal port b hs_b 203 i/o bidirectional horizontal sync signal port b pxq_b 204 i/o bidirectional pixel quali?er signal to mark valid pixels port b; note 2 n.c. 205 - reserved pin; do not connect v ddd25 206 p digital supply voltage 25 (3.3 v) n.c. 207 - reserved pin; not connected internally n.c. 208 - reserved pin; do not connect symbol pin status description fig.3 pin configuration SAA7146AHz (sqfp208). handbook, halfpage SAA7146AHz 1 208 157 53 104 52 156 105 mhb046
1998 apr 09 17 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7 functional description this chapter provides information about the features realized with this device. first, a general, thus short, description of the functionality is given. the following sections deal with the single features in a detailed manner. 7.1 general the dual d1 (dd1) interface can be connected to digital video decoder ics such as the saa7110 and saa7111a, digital video encoder such as the saa7185b, video compression codecs or to a d1 compatible connector, e.g. for interconnection to an external digital camera. the interface supports bidirectional full duplex two channel full d1 (ccir 656), optionally with separate sync lines h/v, pixel qualifier signal and double pixel clock i/o, up to 32 mhz. it also supports a 16-bit parallel yuv bus for interfacing to the saa7110. one of the two internal video processors of the saa7146a is the two-dimensional high performance scaler (hps). phase accurate re-sampling by interpolation supports independent horizontal up and downscaling. in the horizontal direction the scaling process is performed in two functional blocks: integer decimation by window averaging (up to 65 tap), and phase linear interpolation (10 tap filter for luminance, 6 tap filter for chrominance). the vertical processing for downscaling either uses averaging over a window (up to 65 tap) or linear interpolation (2 tap). the scaling function can be used for random sized display windowing, for horizontal upscaling (zoom) or for conversion between various sample schemes such as ccir or sqp. incorporated with the hps function is brightness, contrast and saturation control. colour key generation is also established. the output of the hps can be formatted in various rgb and yuv formats. additionally, this output can be dithered for low bit rate formats. packed formats as well as planar formats (yuv) are supported. a second video channel (yu v4:2:2 format) bypasses the hps and connects the real time video interface with the pci interface. this video bypass channel, using the second video processor binary ratio scaler (brs), is bidirectional and has means to convert from full size video (50 or 60 hz) to common interchange format (cif), quarter common interchange format (qcif) or quarter quarter common interchange format (qqcif) and vice versa (binary ratio 1, 2, 4, 8, 1 2 , 1 4 and 1 8 only). multiple programmable vbi data and test signal regions can be bypassed without processing during each field. the bidirectional digital audio serial interface is based on the i 2 s-bus standard, but supports flexible programming for various data and timing formats. two independent interface circuits control audio data streaming of up to 2 128-bit frame width (bidirectional or simultaneous input/output). five or more i 2 s devices such as the saa7360 and saa7366 (adc) and saa7350 and saa7351 (dac) can be connected gluelessly. the peripheral data port [data expansion bus interface (debi)] enables 8 or 16-bit parallel access for system set-up and programming of peripheral multimedia devices (behind saa7146a), but is also highly capable to interface compressed mpeg/jpeg data of peripheral ics with the pci system. debi supports both intel compatible (isa-bus like) and motorola (68000 style) compatible handshaking protocols with up to 23 mbytes/s peak data rate. besides the parallel port, there is also an i 2 c-bus port to control peripheral ics such as single-chip decoders saa7110 and saa7111a or as encoders such as saa7185b and saa7187 or as audio ics. the pci interface has master read and master write capability. the video signal flows to and from the pci and is controlled by three video dma channels with a total fifo capacity of 384 dwords. the video dma channel definition supports the typical video data structure (hierarchy) of pixels, lines, fields and frames. the audio signal flow is controlled by four audio dma channels, each with 24 dwords fifo capacity. the debi port is connected to the pci by single instruction direct access (immediate mode) and via a data dma channel for streaming data (block mode) with 32 dwords fifo capacity. to improve pci-bus efficiency, an arbiter schedules the access to pci-bus for all local dma channels. the pci interface of the saa7146a supports virtual memory addressing for operating systems running virtual demand paging. the integrated memory management unit (mmu) translates linear addressing to physical addresses using a page table inside the system memory provided by the software driver. the mmu supports up to 4 mbytes of virtual address space per dma channel. the saa7146a can change its programming sets using a register programming sequencer (rps) that works by itself on a user defined program controlled by internally supported real time events. the saa7146a has two rps machines to optimize flow control of e.g. an mpeg compressed data stream and real time video scaling control. the rps programming is defined by an instruction list in the system main memory that consists of multiple rps commands.
1998 apr 09 18 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.2 pci interface this section describes the interface of the saa7146a to the pci-bus. this includes the pci modules, the dma controls of the video, audio and data channels, the memory management unit (mmu) and the internal arbitration control (intac). the handling of the fifos and the corresponding errors are also described and a list of all dma control registers is given. 7.2.1 pci modules and configuration space the saa7146a provides a pci-bus interface having both slave and master capability. the master and the slave module fulfil the pci local bus specification revision 2.1. they decode the c/be# lines to provide a byte-wise access and support 32-bit transfers up to a maximum clock rate of 33 mhz. to increase bus performance, they are able to handle fast back-to-back transfers. during normal operation the saa7146a checks for parity errors and reports them via the perr# pin. if an address parity error is detected the saa7146a will not respond. using the saa7146a as a slave, access is obtained only to the programmable registers and to its configuration space. video, audio and other data of the saa7146a reads/writes autonomously via the master interface (see fig.4). the use of the pci master module, i.e. which dma channel gets access to the pci-bus, is controlled by the intac (see section 7.2.5). the registers described in table 1 are closely related to the pci specification. it should be noted that header type, cache line size, bist, card bus cis pointer and expansion rom base address registers are not implemented. all registers, which are not implemented are treated as read only with a value of zero. some values are loaded after pci reset via i 2 c-bus from eeprom with device address 1010000 (binary). this loading will take approximately 1 ms at 33 mhz pci clock. if any device tries to read or write data from or to the saa7146a during the loading phase after reset, the saa7146a will disconnect with retry.
1998 apr 09 19 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a this text is here in white to force landscape pages to be rotated correctly when browsing through the pdf in the acrobat reader .this text is here in _ white to force landscape pages to be rotated correctly when browsing through the pdf in the acrobat reader.this text is here in this text is here in white to force landscape pages to be rotated correctly when browsing through the pdf in the acrobat reader. white to force land scape pages to be ... a ndbook, full pagewidth mhb047 memory management unit (mmu) internal arbitration control (intac) register programming sequencer (rps) register sets interrupts debi data/request bus requests channel select i 2 c-bus register error manager (ema) pci module master pci module slave register and shadow ram data physical address logic address byte enable bus command new tr eot ce data pci-bus address fifo control (fico) fifo1 fifo2 fifo3 fifo input control (finc) audio fifo1 out video/audio data streams audio fifo1 in audio fifo2 out audio fifo2 in fig.4 block diagram of the pci interface.
1998 apr 09 20 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 1 con?guration space registers address (hex) name bit type description 00 device id 31 to 16 ro 7146h saa7146a vendor id 15 to 0 ro 1131h philips 04 status register 31 - detected parity error 29 - received master abort 28 - received target abort 26 and 25 ro 01 devsel# timing medium 24 - data parity error detected 23 ro 1 fast back-to-back capable command register 9 rw fast back-to-back enable 6 rw parity error response 2 rw bus master enable 1 rw memory space 08 class code 31 to 8 ro 048000h other multimedia device revision id 7 to 0 ro 01h reading these 8 bits returns 01h 0c latency 15 to 8 rw this register speci?es, in units of pci-bus clocks, the value of the latency timer for this pci-bus master 10 base address register 31 to 9 rw this value must be added to the register offset to claim access to the programming registers; the lower 8 bits are forced to zero 8to0 ro 2c subsystem id 31 to 16 ro this value will be loaded after a pci reset from external hardware using the i 2 c-bus; the default value is 0000h subsystem vendor id 15 to 0 ro this value will be loaded after a pci reset from external hardware using the i 2 c-bus; the default value is 0000h 3c max_lat 31 to 24 ro this value will be loaded after a pci reset from external hardware using the i 2 c-bus; the default value is 26h min_gnt 23 to 16 ro this value will be loaded after a pci reset from external hardware using the i 2 c-bus; the default value is 0fh interrupt pin 15 to 8 ro 01h the interrupt pin register tells which interrupt pin the device uses. this device uses interrupt pin inta#. when these bits are read they return 01h. interrupt line 7 to 0 rw the interrupt line register tells which input of the system interrupt controller the devices interrupt pin is connected to
1998 apr 09 21 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.2.2 v ideo dma control the saa7146as dma control is able to support up to three independent video targets or sources respectively. for this purpose it provides three video dma channels. each channel consists of a fifo, a fifo input control (finc) placed on the video side of the fifo, and a fifo control (fico) placed on the pci side of the fifo. channel 1 only supports the unidirectional data stream into the pci memory. it is not able to read data from system memory. however, this access is possible using channels 2 or 3. table 2 surveys the possibilities and purposes of each video dma channel. each fifo, i.e. each dma channel, has its own programming set including base address (doubled for odd and even fields), pitch, protection address, page table base address, several handling mode control bits and a transfer enable bit (tr_e). in addition, each channel has a threshold and a burst length definition for internal arbitration (see table 6, section 7.2.5). to handle the reading modes fifo 2 and fifo 3 offer some additional registers: number of bytes per line (numbytes), number of lines per field (numlines) and the vertical scaling ratio (only fifo 3, see table 69). the programming sets could be reloaded after the previous job is done [video transfer done (vtd)] to support several dma targets per fifo. the programming set currently used is loaded by the register programming sequencer (rps). if the rps is not used, the registers could be rewritten each time, using the saa7146a as a slave. but then the programmer must take care of the synchronization of these write accesses. all registers needed for dma control are described in table 3, except the transfer enable bits, which are described in table 10. the registers are accessed through pci base address with appropriate offset (see table 1). table 2 size, direction and purpose of the video fifos and the associated dma controls fifo size direction purpose fifo 1 128 dwords write to pci fifo 1 buffers data from the hps output and writes into pci memory. in planar mode fifo 1 gets the y data. fifo 2 128 dwords rw planar mode : fifo 2 buffers u data provided by the hps; the associated dma control 2 sends it into the pci memory. clip mode : dma control 2 reads clipping information (clip bit mask or rectangular overlay data) from the pci system memory and buffers it in fifo 2. fifo 3 128 dwords rw planar mode : fifo 3 buffers v data provided by the hps and writes it into the pci memory. chroma keying mode : fifo 3 buffers chroma keying information and writes it into pci memory. brs mode : fifo 3 buffers data provided by the brs. dma control 3 sends it into the pci memory. read mode : dma control 3 reads video data from the pci system memory (the same data up to four times to offer a simple upscaling algorithm) and buffers it in fifo 3.
1998 apr 09 22 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 3 video dma control registers offset (hex) name bit type description 00 baseodd1 31 to 0 rw pci base address for odd ?elds of the upper (or lower if pitch is negative) left pixel of the transferred ?eld 04 baseeven1 31 to 0 rw pci base address for even ?elds of the upper (or lower if pitch is negative) left pixel of the transferred ?eld 08 protaddr1 31 to 2 rw protection address - 1 and 0 - reserved 0c pitch1 31 to 0 rw distance between the start addresses of two consecutive lines of a single ?eld 10 page1 31 to 12 rw base address of the page table (see section 7.2.4) me1 11 rw mapping enable ; this bit enables the mmu - 10 to 8 - reserved limit1 7 to 4 rw interrupt limit ; de?nes the size of the memory range, that raise an interrupt, if its boundaries are passed pv1 3 rw protection violation handling - 2 - reserved swap1 1 and 0 rw endian swapping of all dwords passing the fifo 1: 00 = no swap 01 = two bytes swap (3210 to 2301) 10 = four bytes swap (3210 to 0123) 11 = reserved 14 numlines1 27 to 16 rw number of lines per ?eld; it de?nes the number of quali?ed lines to be processed by the hps per ?eld. this will cut off all the following input lines at the hps input. numbytes1 11 to 0 rw number of pixels per line ; it de?nes the number of quali?ed pixels to be processed by the hps per line. this will cut off all the following pixels at the hps input. 18 baseodd2 31 to 0 rw pci base address for odd ?elds of the upper (or lower if top-down ?ip is selected) left pixel of the transferred ?eld 1c baseeven2 31 to 0 rw pci base address for even ?elds of the upper (or lower if top-down ?ip is selected) left pixel of the transferred ?eld 20 protaddr2 31 to 2 rw protection address - 1 and 0 - reserved 24 pitch2 31 to 0 rw distance between the start addresses of two consecutive lines of a ?eld 28 page2 31 to 12 rw base address of the page table (see section 7.2.4) me2 11 rw mapping enable ; this bit enables the mmu - 10 to 8 - reserved limit2 7 to 4 rw interrupt limit ; de?nes the size of the memory range, that raise an interrupt, if its boundaries are passed pv2 3 rw protection violation handling
1998 apr 09 23 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 28 rw2 2 rw speci?es the data stream direction of fifo 2. a logic 0 enables a write operation to the pci memory. a logic 1 enables a read operation from the pci memory. swap2 1 and 0 rw endian swapping of all dwords passing the fifo 2: 00 = no swap 01 = two byte swap (3210 to 2301) 10 = four byte swap (3210 to 0123) 11 = reserved 2c numlines2 27 to 16 rw number of lines per ?eld: in read mode numlines de?nes the number of lines to be read from system memory. a logic 0 speci?es one line. in write mode this register is not used. numbytes2 11 to 0 rw number of bytes per line: in read mode this de?nes the number of bytes per line to be read from system memory. a logic 0 speci?es one byte. in write mode this register is not used. 30 baseodd3 31 to 0 rw pci base address for odd ?elds of the upper (or lower if top-down ?ip is selected) left pixel of the transferred ?eld 34 baseeven3 31 to 0 rw pci base address for even ?elds of the upper (or lower if top-down ?ip is selected) left pixel of the transferred ?eld 38 protaddr3 31 to 2 rw protection address - 1 and 0 - reserved 3c pitch3 31 to 0 rw distance between the start addresses of two consecutive lines of a ?eld 40 page3 31 to 12 rw base address of the page table (see section 7.2.4) me3 11 rw mapping enable ; this bit enables the mmu - 10 to 8 - reserved limit3 7 to 4 rw interrupt limit ; de?nes the size of the memory range, that raise an interrupt, if its boundaries are passed pv3 3 rw protection violation handling rw3 2 rw speci?es the data stream direction of fifo 3. a logic 0 enables a write operation to the pci memory. a logic 1 enables a read operation from the pci memory. swap3 1 and 0 rw endian swapping of all dwords passing the fifo 3: 00 = no swap 01 = two byte swap (3210 to 2301) 10 = four byte swap (3210 to 0123) 11 = reserved 44 numlines3 27 to 16 rw number of lines per ?eld : in read mode numlines de?nes the number of lines to be read from system memory. a logic 0 speci?es one line. in write mode it de?nes the number of quali?ed lines to be processed by the brs per ?eld. this will cut off all the following input-lines at the brs input. numbytes3 11 to 0 rw number of bytes per line : in read mode this de?nes the number of bytes per line to be read from system memory. a logic 0 speci?es 1 byte. in write mode it de?nes the number of quali?ed bytes to be processed by the brs per line. this will cut off all the following bytes at the brs input. offset (hex) name bit type description
1998 apr 09 24 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a the video channels provide 32 bits of data signals and 4 bits of byte enable (be) signals, end-of-line (eol), end-of-window (eow), begin-of-field (bof), line-locked clock (llc), odd/even signal (oe) and a valid data (vd) signal. to start a video data transfer, e.g. via video dma channel 3, this channel must first be included in the internal arbitration scheme. this is achieved by setting the corresponding tr_e bit (see table 10). if a tr_e bit is not set, the corresponding fifo is reset. in read mode, which is offered by channels 2 and 3, the fico requests a pci transfer with the next bof. data is provided by the pci master module. the fico calculates the pci address autonomously, starting with the base address of the corresponding field. only the received data will be filled into the fifo. fifo 3 offers the possibility to read video information from pci memory, e.g. from the frame buffer. this could be achieved by using the numbytes and the numlines register, which defines the size of the source picture, so that the dma control is able to synchronize itself to the source frame. fifo 2 does the same if reading clip information from memory. to support the binary ratio scaler (brs) included in the saa7146a, which only provides the possibility of horizontal upscaling, the dma control 3 can be applied to perform line repetition by reading lines up to four times from pci memory. this feature is controlled by the vertical scaling ratio in outbound mode (see table 66). this ratio specifies the number of times each line should be read: 00 = only once, 01 = twice, and so on. in the event of fifo underflow, i.e. if the brs or the clipping unit respectively tries to read data from the fifo, even if the dma control was not able to fill any data until that moment, the reading unit tries to synchronize itself to the outgoing data stream as soon as possible. in this way the reading of invalid data is minimized. if the clipping unit receives no data, it will disable the associated pixels. the behaviour of the brs depends on the selected read mode which is described in section 7.10. in the event of fifo overflow, i.e. if the scaler tries to transfer data although the fifo is full, the fifo input control locks the fifo for the incoming data. during fifo overflow the pci address of the incoming data will be increased, over writing itself each time, if the scaler transfers data, which has been clipped, the same mechanism is used to improve pci performance. the saa7146a is able to handle a negative pitch. with that, top-down-flip of the transmitted fields or frames is possible. a negative pitch (msb = 1) leads to a different definition of the protection and the base address, as shown in fig.5. if using negative pitch the first line starts at base address + pitch. in none-rps mode the saa7146a supports the displaying of interlaced video data by using the two different base addresses (baseodd and baseeven) and vertical start phases (ype6 to ype0 and ypo6 to ypo0) for odd and even fields. using the protection address, system memory could be kept of from prohibited write accesses. if the pci pointer of the current transfer reaches or exceeds the protection address, the saa7146a stops this transfer and an interrupt is initiated. no interrupt is set if a protection violation occurs due to the programming that was done before the channel has been switched on. to prevent one field from being transferred into memory, set its base address (baseodd or baseeven) to the same value as the protection address. if the protection violation (pv) handling bit and the limit register are reset, the following data will be ignored until detection of the end-of-window (eow) signal. in read mode the dma control also waits for this signal, to start the next data transfer. if the pv bit is set, the input of the fifo will be locked and the fifo will be emptied. if the fifo is empty the tr_e bit is reset. this feature could be used for a single capture mode, if the protection address is the same address as the last pixel in this field. with that, the saa7146a will write one field into system memory and then stop. if the limit register of any dma channel (video, vbi data or audio) has a value other than 0000 the continuous write mode is chosen. if the actual pci address hits the protection address and the pv bit is zero, the finc stops the current transfer, sets an interrupt and resets the actual address to the base address. regarding this, the protection address could be used to define a memory space to which data is sent. the saa7146a offers the possibility to monitor the filling level of this memory space. the limit register defines an address limit, which generates an interrupt if passed by the actual pci address pointer. 0001 means an interrupt will be generated if the lower 6 bits (64 bytes) of the pci address are zero. 0010 defines a limit of 128 bytes, 0011 one of 256 bytes, and so on up to 1 mbyte defined by 1111. this interrupt range can be calculated as follows: range = 2 (5 + limit) bytes. the protection handling modes such as those selected by the pv bit and the contents of the limit register are shown in table 4.
1998 apr 09 25 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 4 protection violation handling modes note 1. x = dont care. limit pv description 0000 0 lock input of fifo and empty fifo (only in write mode). unlock fifo and start next transfer using the base address at the detection of bof. 0000 0 restart immediately at base address. xxxx (1) 1 lock input of fifo, empty fifo (only in write mode) and then reset tr_e bit. the next transfer starts with bof using the corresponding base address, if the tr_e bit is set again. this setting is useful for single-shot, that means transferring only one frame of a video stream. therefore the protection address has to be the same as the address of the last pixel of the ?eld. fig.5 handling of base and protection address using positive and negative line pitch. handbook, full pagewidth mgg260 positive pitch baseaddr protaddr 1st line positive pitch 2nd line positive pitch 3rd line last line negative pitch (a) positive line pitch (b) positive line pitch baseaddr protaddr 1st line negative pitch 2nd line negative pitch last line
1998 apr 09 26 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.2.3 a udio dma control the saa7146a provides up to four audio dma channels, each using a fifo of 24 dwords. two channels are read only (a1_in and a2_in) and two channels are write only (a1_out and a2_out). because audio represents a continuous data stream, which is neither line nor field dependent, the audio dma control offers only one base address (baseaxx) and no pitch register. for fifo overflow and underflow the handling of these channels is done in the same way as the video dma channels (see section 7.2.2). the protection violation handling differs only if the limit register and the pv bit are programmed to zero. the audio dma channel does not wait for the eof signal, like the video ones. it does not generate interrupts. the interrupt range specified by the limit register is defined in the same way as described in section 7.2.2. the audio dma channels try immediately to transfer data after setting the transfer enable bits. all registers for audio dma control, which are the base address, the protection address and the control bits are listed in the following table 5, except the input control bits (burst, threshold), which are listed in table 6. table 5 audio dma control register offset (hex) name bit type description 94 basea1_in 31 to 0 rw base address for audio input channel 1 ; this value speci?es a byte address 98 prota1_in 31 to 2 rw protection address for audio input channel 1 ; this address could be used to specify a upper limit for audio access in memory space - 1to0 - reserved 9c pagea1_in 31 to 12 rw base address of the page table, see section 7.2.4. mea1_in 11 rw mapping enable ; this bit enables the mmu - 10 to 8 - reserved limita1_in 7 to 4 rw interrupt limit ; de?nes the size of the memory range, that generates interrupt, if its boundaries are passed pva1_in 3 rw protection violation handling - 2to0 - reserved a0 basea1_out 31 to 0 rw base address for audio output channel 1 ; this value speci?es a byte address. the lower two bits are forced to zero. a4 prota1_out 31 to 2 rw protection address for audio output channel 1 ; this address could be used to specify a upper limit for audio access in memory space - 1 and 0 - reserved a8 pagea1_out 31 to 12 rw base address of the page table , see section 7.2.4. mea1_out 11 rw mapping enable ; this bit enables the mmu - 10 to 8 - reserved limita1_out 7 to 4 rw interrupt limit ; de?nes the size of the memory range, that generates an interrupt, if its boundaries are passed pva1_out 3 rw protection violation handling - 2to0 - reserved
1998 apr 09 27 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a ac basea2_in 31 to 0 rw base address for audio input channel 2 ; this value speci?es a byte address. the lower two bits are forced to zero. b0 prota2_in 31 to 2 rw protection address for audio input channel 2 ; this address could be used to specify a upper limit for audio access in memory space - 1 and 0 - reserve b4 pagea2_in 31 to 12 rw base address of the page table , see section 7.2.4 mea2_in 11 rw mapping enable ; this bit enables the mmu - 10 to 8 - reserved limita2_in 7 to 4 rw interrupt limit ; de?nes the size of the memory range, that raise an interrupt, if its boundaries are passed pva2_in 3 rw protection violation handling - 2to0 - reserve b8 basea2_out 31 to 0 rw base address for audio output channel 2 ; this value speci?es a byte address. the lower two bits are forced to zero. bc prota2_out 31 to 2 rw protection address for audio output channel 2 ; this address could be used to specify a upper limit for audio access in memory space - 1 and 0 - reserved c0 pagea2_out 31 to 12 rw base address of the page table , see section 7.2.4 mea2_out 11 rw mapping enable ; this bit enables the mmu - 10 to 8 - reserved limita2_out 7 to 4 rw interrupt limit ; de?nes the size of the memory range, that raise an interrupt, if its boundaries are passed pva2_out 3 rw protection violation handling - 2to0 - reserved offset (hex) name bit type description
1998 apr 09 28 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.2.4 m emory m anagement u nit (mmu) 7.2.4.1 introduction to perform dma transfers, physically continuous memory space is needed. however, operating systems such as microsoft windows are working with virtual demand paging, using a mmu to translate linear to physical addresses. memory allocation is performed in the linear address space, resulting in fragmented memory in the physical address space. there is no way to allocate large buffers of physical, continuous memory, except reserving it during system start-up. thus decreasing the system performance dramatically. to overcome this problem the saa7146a contains a memory management unit (mmu) as well. this mmu is able to handle memory fragmented to 4 kbyte pages, similar to the scheme used by the intel 8086 processor family. the mmu can be bypassed to simplify transfers to non-paged memory such as the graphics adapters frame buffer. 7.2.4.2 memory allocation the saa7146as mmu requires a special scheme for memory allocation. the following steps have to be performed: allocation of n pages, each page being 4 kbytes of size, aligned to a 4 kbyte boundary allocation of one extra page, to be used as page table initialization of the page table. allocation of pages is done in physical address space. operating systems implementing virtual memory provide services to allocate and free these pages. the page table is stored in a separate page. this limits the linear address page to a size of 4 mbytes and results in a 4 kbyte overhead. the page table is organized as an array of n dwords, with each entry giving the physical address of one of the n pages of allocated memory. as pages are aligned to 4 kbytes, the lower 12 bits of each entry are fixed to zero. 7.2.4.3 implementation the saa7146a has up to 8 dma channels (3 video, 4 audio and 1 debi channel) for which the memory mapping is done. each of them provides the linear address to (from) which it wants to send (read) data during the next transfer. their register sets contain a page table base address (pagexx) and a mapping enable bit (mexx). if mexx is set, mapping is enabled. the mmu checks for each channel whether its address has been already translated. if translated, its request can pass to the internal arbitration control (intac) managing the access to the pci-bus. if not, the mmu starts a bus transfer to the page table. the page table entry address could be calculated from the channels pci address and the page table base address, as shown in fig.6. the upper 20 bits of the pci address are replaced by the upper 20 bits of the according page address to generate the mapped pci address. if the pci address crosses a 4 kbyte boundary during a transfer, the mmu stops this transfer and suppresses its request to the intac until it has renewed the page address, which means replacing the upper 20 bits of the current address. to reduce latency the saa7146a will do a pre-fetch, i.e. it will always try to load the next page address in advance.
1998 apr 09 29 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a fig.6 memory management unit (mmu). handbook, full pagewidth mgg261 00001000h page table physical memory (4 kbyte pages) dma address page address me (mapping enable) physical pci address page table entry address page table base address (00006h) 00000h 00007h 0000fh 00017 h 0001fh 015h 000h 007h 00008000h 00009000h 0000a000h 0000d000h 00011000h 00014000h 00016000h 0001e000h = allocated memory space = page table 2 32 32 12 20 '0' 20 20 10 12 10
1998 apr 09 30 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.2.5 i nternal arbitration control the saa7146a has up to three video dma channels, four audio dma channels and three other dma channels (rps, mmu and debi) each trying to get access to the pci-bus. to handle this, an internal arbitration control (intac) is needed. intac controls on the one hand the pci-bus requests and on the other hand the order in which each dma channel gets access to the bus. the basic implementation of the internal arbitration control is a round-robin mechanism on the top, consisting of the rps, the mmu and one of the eight data channels. data channel arbitration is performed using a first come first serve queue architecture, which may consist of up to eight entries. each data channel reaching a certain filling level of its fifo defined by the threshold, is allowed to make an entry into the arbitration queue. the threshold defines the number of dwords needed to start a sensible pci transfer and must be small enough to avoid a loss of data due to an overflow regarding the pci latency time. after each job (video transfer done, vtd) the video channels have to be emptied and are allowed to fill an entry into the queue, even if they have not yet reached their threshold. concurrently to the entry the channel sets a bit which prohibits further entries to this channel. in the worst case, each data channel can have only one entry in the queue. if each channel wants to access the bus, which means the queue is full, an order like the one shown below will be given. mmu rps. first entry of the data channel queue: mmu rps. second entry of the data channel queue: mmu and so on. if intac detects at least one dma channel in the queue or an mmu or an rps request, it signals the need for the bus by setting the req# signal on the pci-bus. if the gnt# signal goes low, the saa7146a is the owner of the bus and makes the pci master module working with the first channel selected. the master module tries to transfer the number of dwords defined in the burst register. for rps the burst length is hardwired to four and for the mmu it is hardwired to two dwords. after that the master module stops this transfer and starts a transfer using the next channel (due to the round-robin). if a dma channel gets its transfer stopped due to a retry, the arbitration control sets the corresponding retry flag. intac tries to end a retried transfer, even if this transfer gets stopped via the transfer enable bit (tr_e). for this reason the transfer enable bits are internally shadowed by intac. a transfer can only be stopped if it has no retry pending. the arbitration control registers (burst and threshold of debi, video 1 to 3, audio 1 to 4) are listed in table 6.
1998 apr 09 31 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 6 arbitration control registers table 7 burst length de?nition table 8 threshold de?nition note 1. the threshold is reached, if the fifo contains at least this number of dwords. offset (hex) name bit type description 48 burstdebi 28 to 26 rw pci burst length of the debi dma channel; see table 7 burst3 20 to 18 rw pci burst length of video channel 3; see table 7 thresh3 17 to 16 rw threshold of fifo 3; see table 8 burst2 12 to 10 rw pci burst length of video channel 2; see table 7 thresh2 9 to 8 rw threshold of fifo 2; see table 8 burst1 4 to 2 rw pci burst length of video channel 1; see table 7 thresh1 1 and 0 rw threshold of fifo 1; see table 8 4c bursta1_in 28 to 26 rw pci burst length of audio input channel 1; see table 7 thresha1_in 25 to 24 rw threshold of audio fifo a1_in; see table 8 bursta1_out 20 to 18 rw pci burst length of audio output channel 1; see table 7 thresha1_out 17 and 16 rw threshold of audio fifo a1_out; see table 8 bursta2_in 12 to 10 rw pci burst length of audio input channel 2; see table 7 thresha2_in 9 and 8 rw threshold of audio fifo a2_in; see table 8 bursta2_out 4 to 2 rw pci burst length of audio output channel 2; see table 7 thresha2_out 1 and 0 rw threshold of audio fifo a2_out; see table 8 value burst length 000 1 dword 001 2 dwords 010 4 dwords 011 8 dwords 100 16 dwords 101 32 dwords 110 64 dwords 111 128 dwords value write mode (1) read mode (1) video audio video audio 00 4 dwords of valid data 1 dword of valid data 4 empty dwords 1 empty dword 01 8 dwords of valid data 4 dwords of valid data 8 empty dwords 4 empty dwords 10 16 dwords of valid data 8 dwords of valid data 16 empty dwords 8 empty dwords 11 32 dwords of valid data 16 dwords of valid data 32 empty dwords 16 empty dwords
1998 apr 09 32 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.2.6 s tatus information of the pci interface table 9 lists the status information that the pci interface makes available to the user in addition to the interrupt sources that are described later. this information is read only. table 9 status bits of the dma control offset (hex) name bit type description 120 vdp1 31 to 0 r logical video dma pointer of fifo 1 124 vdp2 31 to 0 r logical video dma pointer of fifo 2l 128 vdp3 31 to 0 r logical video dma pointer of fifo 3 12c adp1 31 to 0 r logical audio dma pointer of audio output fifo a1_out 130 adp2 31 to 0 r logical audio dma pointer of audio input fifo a1_in 134 adp3 31 to 0 r logical audio dma pointer of audio output fifo a2_out 138 adp4 31 to 0 r logical audio dma pointer of audio input fifo a2_in 13c ddp 31 to 0 r logical debi dma pointer 7.3 main control 7.3.1 g eneral the saa7146a has two dwords of general control to support quick enable/disable switching of any activity of the saa7146a via direct access by the cpu. these main control dwords are split in two parts. the upper parts have 16 bits of bit-mask to allow bit-selective write to the lower part which contains single bit enable/disable control of major interface functions of saa7146a. if a certain bit position is masked with a logic 1 in the mask word (upper 2 bytes) during a write access, then the corresponding bit in the control word (lower 2 bytes) is changed according to the contents of the transmitted data. by that the cpu can easily switch on or off certain selected interfaces of the saa7146a without checking the actual remaining programming (enabling) of the other parts. the programming of registers for the 3 video dma channels, both video processors (hps, brs) and for the interfaces debi and i 2 c-bus is performed by an upload method. this is done to guarantee coherent programming data. during initiation of an upload operation from a shadow ram each of the upld bits [10 to 0] (see table 11) is assigned to a set of registers. if a logic 1 is written into a upld bit all dedicated shadow ram registers containing changed data are uploaded into their working registers immediately. during a read cycle the upld bits give information on whether the shadow ram contains changed data not yet uploaded into the working registers. the upld bits remain high as long as the contents of the shadow ram represents the current programming
1998 apr 09 33 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 10 main control register 1 offset (hex) name bit type description mask word fc m15 to m00 31 to 16 rw 16-bit mask word for bit-selective writes to the control word; when read these bits always return logic 0 control word fc mrst_n 15 rw master reset not: this is the master reset for the saa7146a. writing a logic 0 to this bit will reset the saa7146a to the same state as after a power-on reset. when read this bit always returns a logic 0. - 14 - reserved: when read this bit always returns a logic 0 erps1 13 rw enable register program sequencer task 1 : if erps1 = 1, then any rps task 1 action is enabled. if erps1 = 0, then rps task 1 action does not fetch any more commands. erps0 12 rw enable register program sequencer task 0 : if erps0 = 1, then any rps task 0 action is enabled. if erps0 = 0, then rps task 0 action does not fetch any more commands. edp 11 rw enable debi port pins : if edp = 0, all pins of the debi port are set to 3-state. if edp = 1, then the function of all pins at the debi port is as programmed via the debi registers. evp 10 rw enable real time video ports pins : if evp = 0, all 24 pins of the real time video interface (dd1 port) are 3-stated. if evp = 1, then the function of all pins at the real time video interface (dd1 port) is as programmed by the scaler register; see table 66. eap 9 rw enable audio port pins : if eap = 0, all 14 pins of the audio interface port are set to 3-state. if eap = 1, then the function of all pins at the audio interface is as programmed in section 7.16.3. ei2c 8 rw enable i 2 c port pins : if ei2c = 0, then both pins of the i 2 c-bus interface port are set to 3-state. if ei2c = 1, then the i 2 c-bus interface is enabled and will function as programmed in section 7.17.2. tr_e_debi 7 rw transfer enable bit of the debi. tr_e_1 6 rw transfer enable bit of video channel 1: if set this channel is included in the internal arbitration scheme. if not set, this channel will be ignored and no transfer will start using this fifo. tr_e_2 5 rw transfer enable bit of video channel 2 tr_e_3 4 rw transfer enable bit of video channel 3 tr_e_a2_out 3 rw transfer enable bit of audio channel 2 out tr_e_a2_in 2 rw transfer enable bit of audio channel 2 in tr_e_a1_out 1 rw transfer enable bit of audio channel 1 out tr_e_a1_in 0 rw transfer enable bit of audio channel 1 in
1998 apr 09 34 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 11 main control register 2 offset (hex) name bit type description mask word 100 m15 to m00 31 to 16 rw 16-bit mask word for bit-selective writes to the control word; when read this bits always returns logic 0 control word 100 rps_sig4 15 rw rps signal 4 rps_sig3 14 rw rps signal 3 rps_sig2 13 rw rps signal 2 rps_sig1 12 rw rps signal 1 rps_sig0 11 rw rps signal 0 upld_d1_b 10 rw upload video data stream handling at port d1_b (54h); see table 68. to upload initial setting of dual d1 interface (50h), this bit and bit 9 must be set; see table 66. upld_d1_a 9 rw upload video data stream handling at port d1_a (54h); see table 67. to upload initial setting of dual d1 interface (50h), this bit and bit 10 must be set; see table 66. upld_brs 8 rw upload brs control register (58h); see table 69. - 7 - reserved; when read this bit always returns a logic 0. upld_hps_h 6 rw upload hps horizontal prescale (68h); see table 79. upload hps horizontal ?ne-scale (6ch); see table 81. upload bcs control (70h); see table 82. upld_hps_v 5 rw upload hps control (5ch); see table 71. upload hps vertical scale (60h); see table 72. upload hps vertical scale and gain (64h); see table 73. upload chroma key range (74h); see table 86. upload hps outputs and formats (78h); see table 87. upload clip control (78h); see table 89. upld_dma3 4 rw upload video dma3 registers; 30h, 34h, 38h, 3ch, 40h, 44h and 48h (20 to 16). upld_dma2 3 rw upload video dma2 registers; 18h, 1ch, 20h, 24h, 28h, 2ch and 48h (12 to 8). upld_dma1 2 rw upload video dma1 registers; 00h, 04h, 08h, 0ch, 10h, 14h and 48h (4 to 0). upld_debi 1 rw upload debi registers; 88h, 7ch, 80h, 84h and 48h (28 to 26). upld_iic 0 rw upload i 2 c-bus registers; (8ch and 90h).
1998 apr 09 35 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.4 register programming sequencer (rps) the rps is used as an additional method to program or read the registers of the saa7146a. its main function is programming the registers on demand without delay via the interrupt handler of the host system. because different applications of the saa7146a can run independently on and asynchronously to each other the rps is capable of running two parallel tasks. both tasks are completely equal to each other and each has its own set of registers (rps address, rps page, hbi threshold and rps time out value). each task can be separately enabled by setting its related erpsx bit in the main control register 1 (see table 10). to allow communication between both tasks and the cpu there are five signals which can be set or reset from both tasks (see table 11). the programming of a task is defined by an instruction list in the system main memory that consists of rps commands. the operation of the rps is initiated on command by setting the erps bit of the desired task in the main control register 1. the processing of rps can be controlled by a sequence of wait commands on special events. furthermore the program flow can be controlled via conditional jumps related to the communication with the host setting semaphores or special internal interrupts. 7.4.1 r eset during a reset the erpsx (enable rps of task x) bits in the main control register 1 (see table 10) of the saa7146a are cleared so that an rps task has to be explicitly started. 7.4.2 e vent description table 12 shows the events available during the execution of an rps program. the execution can for example wait on these events to become true. in general these events are set if a rising edge of the corresponding signal occurs and are cleared if a falling edge of the signal occurs. if signals are logic high after the reset and no rising edge occurs the corresponding event (available in an rps program execution) will not be set. table 12 description of events note 1. if an rps program is used to make debi transfer consecutive data blocks employ the following commands: load register, clear signal, upload and pause. before uploading the register contents the debi_done flag of a former transfer has to be cleared. with this, the following pause command waits correctly for debi_done of the just started debi block transfer. event description iicd iic done: done ?ag of the i 2 c-bus debid debi done: done ?ag of debi; see note 1 o_fid_a; o_fid_b field identi?cation signal: for an odd ?eld dependent on sync detection at port a/port b e_fid_a; e_fid_b field identi?cation signal : for an even ?eld dependent on sync-detection at port a/port b hs hps source : wait for processing of source line before line addressed by slct is done ht hps target : wait for processing of target line before line addressed by tlct is done vbi_a; vbi_b vertical blanking indicator at port a/port b: for details on this signal see table 90 brs_done inactive brs data path : for details on this signal see table 90 hps_done inactive hps data path between two windows : for details on this signal see table 90 hps_line_done inactive hps data path between two lines : for details on this signal see table 90 vtd1; vtd2; vtd3 video transfer done : video dma 1, video dma 2 or video dma 3 has transferred a complete window and is ready to be reprogrammed gpio0 general purpose i/o 0 : this bit re?ects the status of the gpio pin 0 gpio1 general purpose i/o 1 : this bit re?ects the status of the gpio pin 1 gpio2 general purpose i/o 2 : this bit re?ects the status of the gpio pin 2 gpio3 general purpose i/o 3 : this bit re?ects the status of the gpio pin 3 sigx general purpose signal x : for intertask and rps to cpu communication or program ?ow control. x can take a value within the range 0 to 4
1998 apr 09 36 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.4.3 c ommand list an instruction list of an rps task is built in the system memory by the device driver. this list is made up of command sequences; each command being at least one dword long. the first dword of a command consists of the instruction code (4-bit) and a command specific part (28 bits). commands longer than one dword contain data in the additional dwords. table 13 command dword 7.4.4 t he instruction code the instruction code identifies one of the following commands (see bits 31 to 28 of tables 14 to 29). 7.4.4.1 pause the pause command is a one dword command. this command contains in the command specific part the events to wait for; see tables 14 and 15. the execution of the rps task is delayed until the condition addressed via the events becomes true or a time out occurs. to control the time a pause command stays in the wait state, it is possible to set a rps time out value. this value specifies after how many pci clocks and/or v_syncs a time out will be asserted. when it occurs the rps_to bits in the psr (see table 38) is set and if enabled an interrupt will be generated. however, the rps will stop this task. the oan bit specifies if the condition in bits 25 to 0 is an and (oan set to 0) or if the condition is an or (oan set to 1). if the inv bit is set this command will wait for the condition to become false. 7.4.4.2 upload the upload command is a one dword-command. this command contains in the command specific part the sections to be uploaded from the shadow ram to the working registers, see tables 16 and 17. if the upload command finds a bit of a section set it uploads the corresponding registers from the shadow ram to the working registers. this is done for registers with changed shadow ram values only. d31 to d28 d27 to d0 instruction code command speci?c 7.4.4.3 check-late the check_late command is a one dword-command. this command contains in the command specific part the events to check and if necessary to wait for, as shown in tables 18 and 19. the execution of the rps task is delayed until the condition addressed via the events becomes true, or a time out occurs and the upload is performed. the oan bit specifies if the condition in bits 25 to 0 is an and (oan set to 0) or if the condition is an or (oan set to 1). if the inv bit is set this command will wait for the condition to become false. if the check_late command finds that the wait condition is already true the rps-late is set. otherwise it waits for the condition as the pause command. a time out behaviour such as described for the pause command is also supplied. 7.4.4.4 clr_signal the clr_signal command clears the selected signals. this will not affect the real status bits of the saa7146a. only a copy of this bit related to the rps will be cleared. it will be set again via a set_signal command or when the real status will be set due to normal processing. the clr_signal format is shown in tables 20 and 21. 7.4.4.5 nop the nop command consists of one dword and has the instruction code 0000. all bits of the command specific part have to be set to zero. this command is a special case of the clr_signal command! 7.4.4.6 set_signal the set_signal command sets the selected signals. if one of the saa7146a status related signals is selected to be set, it will not affect the real status bit of the saa7146a. only a copy of this bit related to the rps, will be set. the set_signal format is shown in tables 22 and 23.
1998 apr 09 37 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.4.4.7 interrupt the interrupt command will set the rps_i bit of the task in the interrupt status register (see table 41) if it is executed and the condition described by the event flags is true. the execution of rps continues. the format of the interrupt command is shown in tables 24 and 25. the oan bit specifies if the condition in bits 25 to 0 is an and (oan set to 0) or if the condition is an or (oan set to 1). if the inv bit is set this command will wait for the condition to become false. 7.4.4.8 stop the stop command will terminate the rps execution and reset the erps-bit. the command specific part of the stop command is like the interrupt command. if the addressed event is true the stop will be executed otherwise the execution will continue with the next command. if no event is addressed the stop will be executed unconditionally. the format of the stop command is shown in tables 26 and 27. the oan bit specifies if the condition in bits 25 to 0 is an and (oan set to 0) or if the condition is an or (oan set to 1). if the inv bit is set this command will wait for the condition to become false. 7.4.4.9 jump the jump command is a two dword command. the second dword contains the physical address at which the rps will continue its execution. the address in the second dword is directly transferred to the rpsaddr register. the command specific part in the first dword of the jump command is like the interrupt command. if the addressed event is true the jump will be performed otherwise the execution will continue at the next command. if no event is addressed the jump will be unconditional. the format of the jump command is shown in tables 28 and 29. the oan bit specifies if the condition in bits 25 to 0 is an and (oan set to 0) or if the condition is an or (oan set to 1). if the inv bit is set this command will wait for the condition to become false.
1998 apr 09 38 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a this text is here in white to force landscape pages to be rotated correctly when browsing through the pdf in the acrobat reader .this text is here in _ white to force landscape pages to be rotated correctly when browsing through the pdf in the acrobat reader.this text is here in this text is here in white to force landscape pages to be rotated correctly when browsing through the pdf in the acrobat reader. white to force land scape pages to be ... table 14 pause command format table 15 pause command format (continued) table 16 upload command format table 17 upload command format (continued) d31 to d28 d27 d26 d25 d24 d23 d22 d21 d20 d19 d18 d17 d16 0010 oan inv sig4 sig3 sig2 sig1 sig0 gpio3 gpio2 gpio1 gpio0 ht d15 d14 d13 d12 d11 d10 d9 d8 d7 d6 d5 d4 d3 d2 d1 d0 hs o_fid_b e_fid_b o_fid_a e_fid_a vbi_a vbi_b brs_done - hps_ line_ done hps_done vtd3 vtd2 vtd1 debid iicd d31 to d28 d25 to d11 d10 d9 d8 d7 d6 0100 reserved video data stream handling at port d1_a (54h); see table 68 video data stream handling at port d1_b (54h); see table 67 brs control register (58h); see table 69 reserved horizontal-prescale (68h); see table 79. horizontal ?ne-scale (6ch); see table 81. bcs control (70h); see table 82 initial setting of dual d1 interface (50h) d5 d4 d3 d2 d1 d0 hps control (5ch); see table 71. hps vertical scale (60h); see table 72. hps vertical scale and gain (64h); see table 73. chroma key range (74h); see table 86. hps output and formats (78h); see table 87. clip control (78h); see table 89. video dma3 (30h, 34h, 38h, 3ch, 40h, 44h, 48h); [20 to 16] video dma2 (18h, 1ch, 20h, 24h, 28h, 2ch, 48h); [12 to 8] video dma1 (00h, 04h, 08h, 0ch, 10h, 14h, 48h); [4 to 0] debi (88h, 7ch, 80h, 84h, 48h); [28 to 26] iic (8ch, 90h)
1998 apr 09 39 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a this text is here in white to force landscape pages to be rotated correctly when browsing through the pdf in the acrobat reader .this text is here in _ white to force landscape pages to be rotated correctly when browsing through the pdf in the acrobat reader.this text is here in this text is here in white to force landscape pages to be rotated correctly when browsing through the pdf in the acrobat reader. white to force land scape pages to be ... table 18 check_late command dword format table 19 check_late command dword format (continued) table 20 clr_signal command format table 21 clr_signal command format (continued) table 22 set_signal command format table 23 set_signal command format (continued) d31 to d28 d27 d26 d25 d24 d23 d22 d21 d20 d19 d18 d17 d16 0011 oan inv sig4 sig3 sig2 sig1 sig0 gpio3 gpio2 gpio1 gpio0 ht d15 d14 d13 d12 d11 d10 d9 d8 d7 d6 d5 d4 d3 d2 d1 d0 hs o_fid_b e_fid_b o_fid_a e_fid_a vbi_a vbi_b brs_done - hps_ line_ done hps_done vtd3 vtd2 vtd1 debid iicd d31 to d28 d27 to d26 d25 d24 d23 d22 d21 d20 d19 d18 d17 d16 0000 reserved sig4 sig3 sig2 sig1 sig0 gpio3 gpio2 gpio1 gpio0 ht d15 d14 d13 d12 d11 d10 d9 d8 d7 d6 d5 d4 d3 d2 d1 d0 hs o_fid_b e_fid_b o_fid_a e_fid_a vbi_a vbi_b brs_done - hps_ line_ done hps_done vtd3 vtd2 vtd1 debid iicd d31 to d28 d27 to d26 d25 d24 d23 d22 d21 d20 d19 d18 d17 d16 0001 reserved sig4 sig3 sig2 sig1 sig0 gpio3 gpio2 gpio1 gpio0 ht d15 d14 d13 d12 d11 d10 d9 d8 d7 d6 d5 d4 d3 d2 d1 d0 hs o_fid_b e_fid_b o_fid_a e_fid_a vbi_a vbi_b brs_done - hps_ line_ done hps_done vtd3 vtd2 vtd1 debid iicd
1998 apr 09 40 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a this text is here in white to force landscape pages to be rotated correctly when browsing through the pdf in the acrobat reader .this text is here in _ white to force landscape pages to be rotated correctly when browsing through the pdf in the acrobat reader.this text is here in this text is here in white to force landscape pages to be rotated correctly when browsing through the pdf in the acrobat reader. white to force land scape pages to be ... table 24 interrupt command format table 25 interrupt command format (continued) table 26 stop command format table 27 stop command format (continued) table 28 jump command format table 29 jump command format (continued) d31 to d28 d27 d26 d25 d24 d23 d22 d21 d20 d19 d18 d17 d16 0110 oan inv sig4 sig3 sig2 sig1 sig0 gpio3 gpio2 gpio1 gpio0 ht d15 d14 d13 d12 d11 d10 d9 d8 d7 d6 d5 d4 d3 d2 d1 d0 hs o_fid_b e_fid_b o_fid_a e_fid_a vbi_a vbi_b brs_done - hps_ line_ done hps_done vtd3 vtd2 vtd1 debid iicd d31 to d28 d27 d26 d25 d24 d23 d22 d21 d20 d19 d18 d17 d16 0101 oan inv sig4 sig3 sig2 sig1 sig0 gpio3 gpio2 gpio1 gpio0 ht d15 d14 d13 d12 d11 d10 d9 d8 d7 d6 d5 d4 d3 d2 d1 d0 hs o_fid_b e_fid_b o_fid_a e_fid_a vbi_a vbi_b brs_done - hps_ line_ done hps_done vtd3 vtd2 vtd1 debid iicd d31 to d28 d27 d26 d25 d24 d23 d22 d21 d20 d19 d18 d17 d16 1000 oan inv sig4 sig3 sig2 sig1 sig0 gpio3 gpio2 gpio1 gpio0 ht d15 d14 d13 d12 d11 d10 d9 d8 d7 d6 d5 d4 d3 d2 d1 d0 hs o_fid_b e_fid_b o_fid_a e_fid_a vbi_a vbi_b brs_done - hps_ line_ done hps_done vtd3 vtd2 vtd1 debid iicd
1998 apr 09 41 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.4.4.10 ldreg and streg the load register (ldreg) command has a variable dword count specified by the block_length. it is at least two dwords long and at maximum 256 dwords. the ldreg command interprets the following dwords as data and writes it to the registers beginning at the specified register address (d6 to d0). the store register (streg) command is a two dword command. it transfers the contents of the addressed (d6 to d0) saa7146a register into pci memory that is addressed by interpreting the contents of the next data dword as the 32-bit target base address. to perform streg by two different tasks, a kind of arbitration with two semaphore signals is necessary. the block_length entry defines the number of data dwords to be processed by these commands. this enables the access to multiple registers on following addresses within a single rps command. the value specified must be at least one. if more than one dword is accessed the register address is incremented each cycle. a value of zero is reserved and the command will be interpreted as nop. the register address defines the target register address in dwords. if this address points to a non-existent register the rps_re (read error) bit for the actual task will be set and if enabled an interrupt will be generated. the command will be ignored and the execution of rps continues. all reserved bits should be written as zeros and should be ignored during read cycles. table 30 ldreg command format table 31 streg command format d31 to d28 d27 to d16 d15 to d8 d7 d6 to d0 1001 reserved block_length reserved register address (register offset divided-by-4) d31 to d28 d27 to d16 d15 to d8 d7 d6 to d0 1010 reserved block_length reserved register address (register offset divided-by-4) fig.7 possible solution employing two semaphore signals to perform streg commands with two tasks. handbook, halfpage mhb048 task0 set sig3 . . . set sig3 clr sig3 jump if sig2 = 0 to streg address set sig3 . . . task1 set sig2 . . . . . . clr sig2 wait on sig3 streg address set sig2 . . .
1998 apr 09 42 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.4.4.11 maskload the maskload command is a three dword command. its purpose is to modify only portions or selected bits of a saa7146a register. the first dword of the command contains the instruction code and specifies the register to be modified. the second dword contains the mask and the third dword contains the data to be written to the register through this mask. the mask works as follows: if a bit in the mask is set, the data from the third dword at the corresponding bit position will be transferred to the register. if a bit in the mask is zero, the corresponding bit in the register will remain unchanged. table 32 maskload command ?rst dword 7.4.5 o peration the operation of the rps is controlled by the enable bits in the main control register 1 (see table 10). if one of these bits is set the related rps task starts its execution with the command addressed by the task related rps_addr register. when a rps task is switched on it immediately starts fetching its data via dma, beginning at the actual address pointers location. four dwords are fetched at a time and loaded into an instruction queue. operation continues to the end of the queue at the time the rps dma loads the next four dwords in the rps list. to monitor the ongoing execution and the end of rps there are status and interrupt bits for each task in the primary status register (psr) and the secondary status register (ssr), see tables 38 and 39. 7.4.6 rps address register the start address of the rps list of each task is defined in the rps address register of the task. the start address must be dword aligned. during an rps list execution this register works like a program counter. since the rps can write data into the main memory of the system a protection mechanism is implemented. there is a 4-kbyte page in the memory for each task in which the rps tasks are allowed to write in. every write access outside this page will cause an error and the rps task will stop immediately. if the corresponding bit in the interrupt enable register is set, an interrupt will be generated. this protection mechanism can be disabled via the enable rps page register (erpspx) bit. this bit is located at bit 0 of the rps page register. a zero enables page errors. this bit is set to 1 after a reset. table 33 rps address register d31 to d28 d27 to d7 d6 to d0 1100 reserved register address (register offset divided-by-4) offset (hex) name bit type description 104 rps_addr0 31 to 2 rw default value: 0 1 and 0 00 108 rps_addr1 31 to 2 rw default value: 0 1 and 0 00
1998 apr 09 43 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 34 rps page register 7.4.7 l ine counter thresholds for the events related to the line counters of the source and the target, (either hps or brs) there are two thresholds for each task in the hbi threshold register (see table 35). the purpose of this register is to set the hs or ht event flag when the corresponding line counter has reached the threshold. these thresholds must be written before waiting on the event. a value of zero as threshold turns the hs or ht event on, for every line. table 35 hbi threshold register offset (hex) name bit type description c4 rps_page0 31 to 12 rw default value: 0 - 11 to 1 - reserved erpsp0 0 rw enable rps page register 0 c8 rps_page1 31 to 12 rw default value: 0 - 11 to 1 - reserved erpsp1 0 rw enable rps page register 1 offset (hex) name bit type description cc - 31 to 29 - reserved tlcs0 28 rw target line counter select for task 0 : this bit de?nes if the tlct0 refers to the hps (logic 0) or to the brs (logic 1) tlct0 27 to 16 rw target counter threshold for task 0 : speci?es the threshold for the target line counter - 15 to 13 - reserved slcs0 12 rw source line counter select for task 0 : the bit de?nes if the slct0 refers to the hps (logic 0) or to the brs (logic 1) slct0 11 to 0 rw source line counter threshold for task 0 : speci?es the threshold for the source line counter d0 - 31 to 29 - reserved tlcs1 28 rw target line counter select for task 1 : this bit de?nes if the tlct refers to the hps (logic 0) or to the brs (logic 1) tlct1 27 to 16 rw target line counter threshold for task 1 : speci?es the threshold for the target line counter - 15 to 13 - reserved slcs1 12 rw source line counter select for task 1 : this bit de?nes if the slct1 refers to the hps (logic 0) or to the brs (logic 1) slct1 11 to 0 rw source line counter threshold for task 1 : speci?es the threshold for the source line counter
1998 apr 09 44 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.4.8 rps time out value these registers contain the values for the time out conditions of the pause and check_late commands for each task. if the selected counter value is zero, the time out generation is disabled. table 36 rps time out value table 37 rps_tox generation offset (hex) name bit type description d4 v_to0 31 rw these two bits determine how the rps_to0 is generated; see table 37 c_to0 30 rw v_abn0 29 rw this bit determines which port the v_sync for the time out check comes from: a logic 1 selects port a; a logic 0 selects port b - 28 - reserved vsync_cnt0 27 to 24 rw this is a 4-bit value which sets the v_sync time out between 1 and 15 v_syncs pci_cnt0 23 to 0 rw this value speci?es after how many pci clocks a time out should be detected d8 v_to1 31 rw these two bits determine how the rps_to1 is generated; see table 37 c_to1 30 rw v_abn1 29 rw this bit determines which port the v_sync for the time out check comes from: a logic 1 selects port a; a logic 0 selects port b - 28 - reserved vsync_cnt1 27 to 24 rw this is a 4-bit value which sets the v_sync time out between 1 and 15 v_syncs pci_cnt1 23 to 0 rw this value speci?es after how many pci clocks a time out should be detected v_tox c_tox rps_tox generated format 0 0 no time out check 0 1 pci clock time out check 1 0 v_sync time out check 1 1 both time out checks
1998 apr 09 45 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.5 status and interrupts 7.5.1 g eneral in order to control the saa7146a, the status information is collected and stored in two status registers: primary status register (psr) and secondary status register (ssr). these two registers follow a hierarchical approach because the psr contains summed up information from the ssr. interrupts can only be generated from the psr and are enabled via the interrupt enable register (ier). if an interrupt condition occurs and the interrupt is enabled, the corresponding bit in the interrupt status register (isr) is set. these bits can be cleared by writing a logic 1. both status registers are read only. writing a logic 1 into any of the psr bits causes the corresponding interrupt to be generated if enabled. writing a logic 0 has no effect. table 38 primary status register offset (hex) name bit type description reset 110 ppef 31 r pci parity error : this bit is set when a pci parity error occurs during any transfer other than real time video data. the bit in the isr is set on the rising edge of this status bit. isr [31] pabo 30 r pci access error : this bit is set when the pci interface starts an access, and has either a target or master abort. the bit in the isr is set on the rising edge of this status bit. isr [30] pped 29 r pci parity errors on real time data : this bit is set when a parity error has occurred since the last vsync or under rps since the last wait. - rps_i1 28 r interrupt issued by rps command from task 1 . - rps_i0 27 r interrupt issued by rps command from task 0 . - rps_late1 26 r rps task 1 late : this is set by the check_late command. this bit is reset by starting a new rps task 1. - rps_late0 25 r rps task 0 late : this is set by the check_late command. this bit is reset by starting a new rps task 0. - rps_e1 24 r rps_error task 1 : this bit re?ects the status of the rps error bits for task 1 in the secondary status register (see table 39). this bit is reset by starting a new rps task 1. - rps_e0 23 r rps_error task 0 : this bit re?ects the status of the rps error bits for task 0 in the secondary status register (see table 39). this bit is reset by starting a new rps task 0. - rps_to1 22 r rps time out error in task 1 : this bit is set when the rps task 1 stays longer than expected in the wait state. this bit is reset by starting a new rps task 1. -
1998 apr 09 46 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 110 rps_to0 21 r rps time out error in task 0 : this bit is set when the rps task 0 stays longer than expected in the wait state. this bit is reset by starting a new rps task 0. - upld 20 r rps in upload : this bit is active while rps uploads the working registers from the shadow ram. the bit in the isr is set on the falling edge of this status bit. - debi_s 19 r debi status : this bit stays set as long as debi is processing or halted by an error. the bit in the isr is set on the falling edge of this status bit, which indicates a debi done. - debi_e 18 r debi event : this bit is set when one of the two debi event ?ags (debi_ef or debi_to) in the ssr is set. this bit is reset when a new debi command starts. the reset value of debi_to is a logic 1. - iic_s 17 r i 2 c-bus status : this bit stays set as long as the i 2 c-bus is transmitting data or halted by an error. the bit in the isr is set on the falling edge of this status bit, which indicates an i 2 c done. - iic_e 16 r i 2 c-bus error : this bit gets set when one of the i 2 c-bus status bits in the ssr is set. this bit is reset when a new i 2 c-bus transfer starts. - a2_in 15 r audio input dma2 protection : this bit is set when the audio input dma2 address generation exceeded an address boundary or hit its limit (protection address). it is reset with starting the dma channel again. - a2_out 14 r audio output dma2 protection : this bit is set when the audio output dma2 address generation exceeded an address boundary or hit its limit (protection address). it is reset with starting the dma channel again. - a1_in 13 r audio input dma1 protection : this bit is set when the audio input dma1 address generation exceeded an address boundary or hit its limit (protection address). it is reset with starting the dma channel again. - a1_out 12 r audio output dma1 protection : this bit is set when the audio output dma1 address generation exceeded an address boundary or hit its limit (protection address). it is reset with starting the dma channel again. - afou 11 r audio fifo over?ow/under?ow : this bit gets set when one of the four audio fifos has an under?ow or over?ow. - v_pe 10 r video address protection error : this bit is set when one of the video dmas 1 to 3 has an address protection error during an active transmission. - vfou 9 r video fifo over?ow/under?ow : this bit is set if any of the video fifos 1, 2 or 3 has an over?ow or under?ow. - offset (hex) name bit type description reset
1998 apr 09 47 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 39 secondary status register 110 fida 8 r field id port a : via the fidesa bits in the initial setting of the dual d1 interface (see table 66), selected edge(s) of this signal will set the corresponding bit in the isr when enabled. - fidb 7 r field id port b : via the fidesb bits in the initial setting of the dual d1 interface (see table 66), selected edge(s) of this signal will set the corresponding bit in the isr when enabled. - pin3 6 r gpio pin 3 : this bit re?ects the state of the general purpose pin 3. via the gpio register, selected edge(s) of this signal will set the corresponding bit in the isr when enabled. - pin2 5 r gpio pin 2 : this bit re?ects the state of the general purpose pin 2. via the gpio register, selected edge(s) of this signal will set the corresponding bit in the isr when enabled. - pin1 4 r gpio pin 1 : this bit re?ects the state of the general purpose pin 1. via the gpio register selected edge(s) of this signal will set the corresponding bit in the isr when enabled. - pin0 3 r gpio pin 0 : this bit re?ects the state of the general purpose pin 0. via the gpio register selected edge(s) of this signal will set the corresponding bit in the isr when enabled. - ecs 2 r event counter status : this bit re?ects the status of the four (ssr) event counter status bits ec5s, ec4s, ec2s and ec1s. - ec3s 1 r event counter 3 status : this bit is set when event counter 3 exceeds its threshold. - ec0s 0 r event counter 0 status : this bit is set when event counter 0 exceeds its threshold. - offset (hex) name bit type description 114 prq 31 r pci request pending : this bit is set while the pci has asserted its req# signal and has not received a gnt# yet pma 30 r pci master access : this bit is active as long as the saa7146a acts as a master on the pci-bus rps_re1 29 r rps task 1 register access error : this bit is set when the ldreg, streg or maskwrite command tries to access a non-existing register. this bit is reset by writing a logic 1 to the rps_e1 bit in the isr or when a new rps task 1 is started. rps_pe1 28 r rps task 1 page error : this bit is set when the rps task 1 tries to write to an address outside the 4-kbyte page. this bit is reset by writing a logic 1 to the rps_e1 bit in the isr or when a new rps task 1 is started. rps_a1 27 r rps task 1 active : this bit is set whenever rps task 1 is executing and not staying in a wait condition or uploading the working registers offset (hex) name bit type description reset
1998 apr 09 48 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 114 rps_re0 26 r rps task 0 register access error : this bit is set when the ldreg, streg or maskwrite command tries to access a non-existing register. this bit is reset by writing a logic 1 to the rps_e0 bit in the isr or when a new rps task 0 is started. rps_pe0 25 r rps task 0 page error : this bit is set when the rps task 0 tries to write-access an address outside the 4-kbyte page. this bit is reset by writing a logic 1 to the rps_e0 bit in the isr or when a new rps task 0 is started. rps_a0 24 r rps task 0 active : this bit is set whenever rps task 0 is executing and not staying in a wait condition or uploading the working registers debi_to 23 r debi time out : this bit is set when the timeout value was reached. this bit is reset by writing a logic 1 to the debi_e bit in the isr. reset value is a logic 1. debi_ef 22 r debi format error : this bit indicates an illegal command to immediate transfer across a dword boundary. this bit is reset by writing a logic 1 to the debi_e bit in the isr. iic_ea 21 r i 2 c-bus address error : this bit is set when there is no acknowledge after the device address. this bit is reset by writing a logic 1 to the iic_e bit in the isr or when a new i 2 c-bus command starts. iic_ew 20 r i 2 c-bus write data error : this bit is set when there is no acknowledge during the writing of the data byte(s). this bit is reset by writing a logic 1 to the iic_e bit in the isr or when a new i 2 c-bus command starts. iic_er 19 r i 2 c-bus read data error this bit is set when there is no acknowledge during reading of the data byte(s). this bit is reset by writing a logic 1 to the iic_e bit in the isr or when a new i 2 c-bus command starts. iic_el 18 r i 2 c-bus loss arbitration error : this bit is set when the i 2 c-bus loses its arbitration. this bit is reset by writing a logic 1 to the iic_e bit in the isr or when a new i 2 c-bus command starts. iic_ef 17 r i 2 c-bus frame error : this bit is set when there is an invalid start/stop condition since the last i 2 c-bus command. this bit is reset by writing a logic 1 to the iic_e bit in the isr or when a new i 2 c-bus command starts. v3p 16 r video dma 3 protection error : this bit is set when video dma3 generates an address during an active transmission beyond its protection address. this bit is reset by writing a logic 1 to the v_pe bit in the isr or by reloading the dma base address. v2p 15 r video dma 2 protection error : this bit is set when video dma2 generates an address during an active transmission beyond its protection address. this bit is reset by writing a logic 1 to the v_pe bit in the isr or by reloading the dma base address. v1p 14 r video dma 1 protection error : this bit is set when video dma1 generates an address during an active transmission beyond its protection address. this bit is reset by writing a logic 1 to the v_pe bit in the isr or by reloading the dma base address. vf3 13 r video fifo 3 under?ow/over?ow : this bit is set when the video fifo 3 has an over?ow/under?ow. this bit is reset when reloading the dma base address or by writing a logic 1 to the vfou bit in the isr. offset (hex) name bit type description
1998 apr 09 49 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 114 vf2 12 r video fifo 2 under?ow/over?ow : this bit is set when the video fifo 2 has an over?ow/under?ow. this bit is reset when reloading the dma base address or by writing a logic 1 to the vfou bit in the isr. vf1 11 r video fifo 1 over?ow : this bit is set when the video fifo 1 has an over?ow. this bit is reset when reloading the dma base address or by writing a logic 1 to the vfou bit in the isr. af2_in 10 r audio input fifo 2 under?ow : this bit is set when the audio input fifo 2 has an under?ow. this bit is reset by restarting the dma channel or by writing a logic 1 to the afou bit in the isr. af2_out 9 r audio output fifo 2 over?ow : this bit is set when the audio output fifo 2 has an over?ow. this bit is reset by restarting the dma channel or by writing a logic 1 to the afou bit in the isr. af1_in 8 r audio input fifo 1 under?ow : this bit is set when the audio input fifo 1 has an under?ow. this bit is reset by restarting the dma channel or by writing a logic 1 to the afou bit in the isr. af1_out 7 r audio output fifo 1 over?ow : this bit is set when the audio output fifo 1 has an over?ow. this bit is reset by restarting the dma channel or by writing a logic 1 to the afou bit in the isr. - 6 - reserved vgt 5 r vertical gate : this bit re?ects the vertical gate at the hps output lnqg 4 r line quali?er gate : this bit re?ects the horizontal gate at the hps output ec5s 3 r event counter 5 status : this bit is set when the event counter 5 exceeds its threshold. this bit is reset by writing a logic 1 to the ecs bit in the isr. ec4s 2 r event counter 4 status : this bit is set when event counter 4 exceeds its threshold. this bit is reset by writing a logic 1 to the ecs bit in the isr. ec2s 1 r event counter 2 status : this bit is set when event counter 2 exceeds its threshold. this bit is reset by writing a logic 1 to the ecs bit in the isr. ec1s 0 r event counter 1 status : this bit is set when event counter 1 exceeds its threshold. this bit is reset by writing a logic 1 to the ecs bit in the isr. offset (hex) name bit type description
1998 apr 09 50 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 40 interrupt enable register offset (hex) name bit type description dc ppef 31 rw pci parity error interrupt enable pabo 30 rw pci access error interrupt enable pped 29 rw pci parity errors on real time data interrupt enable rps_i1 28 rw enables interrupts issued by rps commands in task 1 rps_i0 27 rw enables interrupts issued by rps commands in task 0 rps_late1 26 rw rps task 1 late interrupt enable rps_late0 25 rw rps task 0 late interrupt enable rps_e1 24 rw rps_error1 interrupt enable rps_e0 23 rw rps_error0 interrupt enable rps_to1 22 rw rps time out task 1 interrupt enable rps_to0 21 rw rps time out task 0 interrupt enable upld 20 rw rps upload interrupt enable debi_s 19 rw debi status interrupt enable debi_e 18 rw debi error interrupt enable iic_s 17 rw i 2 c status interrupt enable iic_e 16 rw i 2 c error interrupt enable a2_in 15 rw audio input dma2 protection interrupt enable a2_out 14 rw audio output dma2 protection interrupt enable a1_in 13 rw audio input dma1 protection interrupt enable a1_out 12 rw audio output dma1 protection interrupt enable afou 11 rw audio fifo over?ow/under?ow interrupt enable v_pe 10 rw video address protection error interrupt enable vfou 9 rw video fifo over?ow/under?ow interrupt enable fida 8 rw field id port a interrupt enable fidb 7 rw field id port b interrupt enable pin3 6 rw gpio pin 3 interrupt enable pin2 5 rw gpio pin 2 interrupt enable pin1 4 rw gpio pin 1 interrupt enable pin0 3 rw gpio pin 0 interrupt enable ecs 2 rw event counter 1, 2, 4 and 5 status interrupt enable ec3s 1 rw event counter 3 status interrupt enable ec0s 0 rw event counter 0 status interrupt enable
1998 apr 09 51 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 41 interrupt status register offset (hex) name bit type description 10c ppef 31 rw pci parity error interrupt status pabo 30 rw pci access error interrupt status pped 29 rw pci parity errors on real time data interrupt status rps_i1 28 rw interrupt issued by rps command from task 1 interrupt status rps_i0 27 rw interrupt issued by rps command from task 0 interrupt status rps_late1 26 rw rps task 1 is late interrupt status rps_late0 25 rw rps task 0 is late interrupt status rps_e1 24 rw rps_error from task 1 interrupt status rps_e0 23 rw rps_error from task 0 interrupt status rps_to1 22 rw rps time out task 1 interrupt status rps_to0 21 rw rps time out task 0 interrupt status upld 20 rw rps upload interrupt status debi_s 19 rw debi status interrupt status debi_e 18 rw debi error interrupt status iic_s 17 rw i 2 c status interrupt status iic_e 16 rw i 2 c error interrupt status a2_in 15 rw audio input dma2 protection interrupt status a2_out 14 rw audio output dma2 protection interrupt status a1_in 13 rw audio input dma1 protection interrupt status a1_out 12 rw audio output dma1 protection interrupt status afou 11 rw audio fifo over?ow/under?ow interrupt status v_pe 10 rw video address protection error interrupt status vfou 9 rw video fifo over?ow/under?ow interrupt status fida 8 rw field id port a interrupt status fidb 7 rw field id port b interrupt status pin3 6 rw gpio pin 3 interrupt status pin2 5 rw gpio pin 2 interrupt status pin1 4 rw gpio pin 1 interrupt status pin0 3 rw gpio pin 0 interrupt status ecs 2 rw event counter 1, 2, 4 and 5 interrupt status ec3s 1 rw event counter 3 interrupt status ec0s 0 rw event counter 0 interrupt status
1998 apr 09 52 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.6 general purpose inputs/outputs (gpio) 7.6.1 g eneral the saa7146a has four general purpose i/o pins. for example, they could be used to signal to other devices a power-down mode or to map an internal status bit to it, e.g. to detect a sync lost from the vblk pin of the saa7110. table 42 gpio registers table 43 gpio control register 7.7 event counter the event counters in the saa7146a provide the possibility of obtaining a statistical look at the different interrupt sources. for this purpose six counters are implemented in two registers (ec1r and ec2r). each register contains one 12-bit counter and two 10-bit counters. to be flexible in the information collected in the counters it is possible to map each status bit to any counter. this is done via the event counter source select register (ecssr). the four 10-bit counters and the two 12-bit counters are able to select one of the 64 possible sources (see table 47). in addition to the counting, it is possible to generate interrupts via threshold values for the counters. these thresholds are kept in the two event threshold registers (et1r and et2r). if a counter exceeds its threshold, it is reset to zero and the corresponding status bit is set. table 44 event counter set 1 register (ec1r) offset (hex) name bit type description e0 gpio3 31 to 24 rw gpio3 control register gpio2 23 to 16 rw gpio2 control register gpio1 15 to 8 rw gpio1 control register gpio0 7 to 0 rw gpio0 control register bit 7 bit 6 bit 5 bit 4 bit 3 bit 2 bit 1 bit 0 description 000 0xxxx input, no interrupt condition 000 1xxxx input, rising edge is interrupt condition 001 0xxxx input, falling edge is interrupt condition 001 1xxxx input, both edges are interrupt condition 01x0xxxx output, ?xed constant low 01x1xxxx output, ?xed constant high 10xxxxxx reserved 1 1 sba[5] sba[4] sba[3] sba[2] sba[1] sba[0] output, monitoring the selected status bits of psr or ssr; see table 48 offset (hex) name bit type description 118 ec2 [9:0] 31 to 22 r event counter two : this is the second 10-bit counter ec1 [9:0] 21 to 12 r event counter one : this is the ?rst 10-bit counter ec0 [1:0] 11 to 0 r event counter zero : this is the ?rst 12-bit counter
1998 apr 09 53 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 45 event counter set 2 register (ec2r) table 46 event counter set 1 source select register 1 (ec1ssr) table 47 event counter set 2 source select register (ec2ssr) table 48 status bit addresses (sba) offset (hex) name bit type description 11c ec5 [9:0] 31 to 22 r event counter five : this is the fourth 10-bit counter ec4 [9:0] 21 to 12 r event counter four : this is the third 10-bit counter ec3 [11:0] 11 to 0 r event counter three : this is the second 12-bit counter offset (hex) name bit type description e4 - 31 to 24 - reserved ecs2 [5:0] 23 to 18 rw event counter 2 source : this 6 bit value addresses one of the status bits ecen2 17 rw event counter 2 enable : if this bit is set, event counter 2 is enabled ecclr2 16 rw event counter 2 clear : writing a logic 1 to this bit will clear event counter 2 ecs1 [5:0] 15 to 10 rw event counter 1 source : this 6 bit value addresses one of the status bits ecen1 9 rw event counter 1 enable : if this bit is set event counter 1 is enabled ecclr1 8 rw event counter 1 clear : writing a logic 1 to this bit will clear event counter 1 ecs0 [5:0] 7 to 2 rw event counter 0 source : this 6 bit value addresses one of the status bits ecen0 1 rw event counter 0 enable : if this bit is set event counter 0 is enabled ecclr0 0 rw event counter 0 clear : writing a logic 1 to this bit will clear event counter 0 offset (hex) name bit type description e8 - 31 to 24 - reserved ecs5 [5:0] 23 to 18 rw event counter 5 source : this 6 bit value addresses one of the status bits ecen5 17 rw event counter 5 enable : if this bit is set the event counter 5 is enabled ecclr5 16 rw event counter 5 clear : writing a logic 1 to this bit will clear event counter 5 ecs4 [5:0] 15 to 10 rw event counter 4 source : this 6 bit value addresses one of the status bits ecen4 9 rw event counter 4 enable : if this bit is set event counter 4 is enabled ecclr4 8 rw event counter 4 clear : writing a logic 1 to this bit will clear event counter 4 ecs3 [5:0] 7 to 2 rw event counter 3 source : this 6 bit value addresses one of the status bits ecen3 1 rw event counter 3 enable : if this bit is set event counter 3 is enabled ecclr3 0 rw event counter 3 clear : writing a logic 1 to this bit will clear event counter 3 address (hex) status bit events to be counted 00 ppef number of pci parity errors 01 pabo number of pci access errors 02 pped every pci clock cycle with data parity error 03 rps_i1 number of rps interrupts task 1
1998 apr 09 54 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 04 rps_i0 number of rps interrupts task 0 05 rps_late1 number of rps late errors for task 1 06 rps_late0 number of rps late errors for task 0 07 rps_e1 number of rps errors for task 1 08 rps_e0 number of rps errors for task 0 09 rps_to1 number of time outs for rps task 1 0a rps_to0 number of time outs for rps task 0 0b upld time for upload, in pci clocks 0c debi_s time debi is busy, in pci clocks 0d debi_e number of debi events in total 0e iic_s time i 2 c-bus is busy, in pci clocks 0f iic_e number of i 2 c-bus errors in total 10 a2_in number of protection hits 11 a2_out number of protection hits 12 a1_in number of protection hits 13 a1_out number of protection hits 14 afou number of audio fifos over?ows/under?ows in total 15 v_pe number of video fifo protection violations in total 16 vfou number of video fifos over?ows/under?ows in total 17 fida number of odd/even ?elds on port a (de?ned via fidesa) 18 fidb number of odd/even ?elds on port b (de?ned via fidesb) 19 pin3 number of active edges as de?ned in the gpio registers; see table 43 1a pin2 number of active edges as de?ned in the gpio registers; see table 43 1b pin1 number of active edges as de?ned in the gpio registers; see table 43 1c pin0 number of active edges as de?ned in the gpio registers; see table 43 1d ecs number of threshold over?ows from ec1, ec2, ec4 and ec5 in total 1e ec3s number of threshold over?ows of ec3s 1f ec0s number of threshold over?ows of ec0s 20 prq time from req# to gnt#, in pci clocks 21 pma time in active master mode, in pci clocks 22 rps_re1 number of rps register access errors for task 1 23 rps_pe1 number of page errors for rps task 1 24 rps_a1 time of rps task 1 busy, in pci clocks 25 rps_re0 number of rps register access errors for task 0 26 rps_pe0 number of page errors for rps task 0 27 rps_a0 time of rps task 0 busy, in pci clocks 28 debi_to number of debi time out events 29 debi_ef number of format errors on debi port 2a iic_ea number of address errors on the i 2 c-bus 2b iic_ew number of i 2 c-bus write data errors address (hex) status bit events to be counted
1998 apr 09 55 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 49 event counter threshold set 1 register (ect1r) note 1. each of these threshold values shows the limit up to which the related counter will run before it sets its interrupt status bit. 2c iic_er number of i 2 c-bus read data errors 2d iic_el number of arbitration losses on the i 2 c-bus 2e iic_ef number of i 2 c-bus frame errors 2f v3p number of protection violations for video fifo 3 30 v2p number of protection violations for video fifo 2 31 v1p number of protection violations for video fifo 1 32 vf3 number of missed dwords 33 vf2 number of missed dwords 34 vf1 number of missed dwords 35 af2_in number of missed dwords 36 af2_out number of missed dwords 37 af1_in number of missed dwords 38 af1_out number of missed dwords 39 - reserved 3a vgt number of v_syncs in acquisition of hps 3b lnqg number of output lines 3c ec5s number of threshold over?ows of ec5 3d ec4s number of threshold over?ows of ec4 3e ec2s number of threshold over?ows of ec2 3f ec1s number of threshold over?ows of ec1 offset (hex) name bit type description ec ect2 [9:0] 31 to 22 rw event counter 2 threshold : this is the threshold for the second 10-bit counter; see note 1 ect1 [9:0] 21 to 12 rw event counter 1 threshold : this is the threshold for the ?rst 10-bit counter; see note 1 ect0 [11:0] 11 to 0 rw event counter 0 threshold : this is the threshold for the ?rst 12-bit counter; see note 1 address (hex) status bit events to be counted
1998 apr 09 56 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 50 event counter threshold set 2 register (ect2r) note 1. each of these threshold values shows the limit up to which the related counter will run before it sets it interrupt status bit. 7.8 video processing 7.8.1 t he real time video interface the real time video interface consists of two bidirectional 8-bit wide ports transporting colour difference samples and luminance samples in a byte sequential manner. each of the two video ports (a and b) has its own clock pin, pixel qualifier and horizontal and vertical sync signal pin. the sync signal can be optionally coded in sav and eav codes according to the d1 standard (smpte125m or ccir 656). the two 8-bit ports can be combined to form a single 16-bit wide yuv port to be compatible to the dmsd2 output format. offset (hex) name bit type description f0 ect6 [9:0] 31 to 22 rw event counter 5 threshold : this is the threshold for the fourth 10-bit counter; see note 1 ect5 [9:0] 21 to 12 rw event counter 4 threshold : this is the threshold for the third 10-bit counter; see note 1 ect4 [11:0] 11 to 0 rw event counter 3 threshold : this is the threshold for the second 12-bit counter; see note 1 fig.8 the real time video interface. handbook, full pagewidth mhb049 d1_a video data stream handling pxq_a hs_a vs_a llc_a llc_b vs_b hs_b pxq_b d1_b 56h vid_a video data stream handling 54h vid_b initial settings of dual d1 interface 52h sio_a initial settings of dual d1 interface 50h sio_b
1998 apr 09 57 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.8.2 dd1: d ual d1 (ccir 656, smpte125m), i/o 7.8.2.1 cb-y-cr-y 8-bit wide stream in this mode two video ports with yuv 4 :2:2 sampling scheme are available. each d1 port has an i/o capability and has a separate clock input and separate sync lines. in this format the pixel rate is equivalent to the clock rate llc. the colour difference signal sample and luminance signal sample (straight binary) are byte-wise multiplexed into the same 8-bit wide data stream, with sequence and timing in accordance with ccir 656 recommendation (respectively according to d1 for 60 hz application). the incoming and scaled data are reformatted to 16-bit for the hps data path and the corresponding reference signals are generated. a discontinuous data stream is supported by accepting or generating a pixel/byte qualifying signal (pxq = 1: qualified pixel, pxq = 0: invalid data, see fig.9). the start condition for synchronizing to the correct cb-y-cr-y sequence is given by the selected horizontal reference signal. the sequence increments only with qualified bytes. fig.9 timing of pxq_x for serial 8-bit data input at the d1_x port. handbook, full pagewidth d1_x (7 to 0) mhb050 pxq_x hs_x llc_x cr y cb y cb y
1998 apr 09 58 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.8.2.2 yuv 16-bit parallel (dmsd2) stream in this mode only the hps data path is available since the brs data path supports only 8-bit wide data streams. colour difference signal and luminance signal (straight binary) are available in parallel on a 16-bit wide data stream. in this mode both d1 ports are inputs (see fig.10). with this format the pixel rate is half the clock rate llc. the start condition for synchronising the clock divider and/or the correct u-v sequence is given by the cref signal, which must be connected to the same port as the colour difference signal. 7.8.3 v ideo data formats on dd1 d1 (smpte125m, ccir 656) as well as yuv16 represent both the same 4 :2:2 sample scheme. both formats, d1 and yuv16, are assumed to agree with the ccir recommendation 601 coding: y = 16 = black, 0% y = 235 = white, 100% brightness u,v = 128 = no colour, 0% saturation u,v = 128 112 = full colour, 100% saturation. data path processing in hps and brs is not limited to this range and allows overshoots and uses margins for processing. the reference values can be manipulated by the bcs processing in the hps data path. 7.8.4 v ideo timing reference codes (sav and eav) there are two timing reference codes; one at the beginning of each video data block [start of active video (sav)] and one at the end of each video data block [end of active video (eav)] as shown in fig.11. each timing reference code consists of a four byte sequence in the following format: ff 00 00 xy. (values are expressed in hexadecimal notation: codes ff, 00 are reserved for use in timing reference codes). the first three bytes are a fixed preamble. the fourth byte contains information defining field identification, the state of field blanking and the state of line blanking. the assignment of bits within the timing reference code is given in table 51. fig.10 timing of pxq_x for 16-bit data input at the d1_x port. handbook, full pagewidth d1_a (7 to 0) cr0 mhb051 pxq_a (cref) hs_x d1_b (7 to 0) llc cr2 y3 cb4 cr4 cb2 y0 cb0 y2 y4 y5 y1
1998 apr 09 59 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 51 video timing reference codes notes 1. f = logic 0 during field 1 and logic 1 during field 2. 2. v = logic 0 elsewhere and logic 1 during field blanking. 3. h = logic 0 in sav and logic 1 in eav. 4. p 0 ,p 1 ,p 2 and p 3 : protection bits (see table 52). bits p 0 ,p 1 ,p 2 and p 3 , have states dependent on the states of the bits f, v and h as shown in table 52. at the receiver (saa7146a) this arrangement permits one-bit errors to be corrected. if two-bit errors or up to four-bit errors occur, i. e. depending on uncoded protection bits, the circuit processes direct on the coded values. in this case the protection bits are ignored. sav and eav are only decoded and removed from the signal stream (substituted with neighbouring first or last active video sample), if chosen this way. however, single qualified codes of 00 and/or ff in the data stream, remain in the data stream and are processed as data. byte bit number 7 (msb) 6 5 4 3 2 1 0 (lsb) first 1 1 1 1 1 1 1 1 second 0 0 0 0 0 0 0 0 third 0 0 0 0 0 0 0 0 fourth 1 f (1) v (2) h (3) p 3 (4) p 2 (4) p 1 (4) p 0 (4) fig.11 timing of pxq_x for ccir 656 at the d1_x port. handbook, full pagewidth d1_x (7 to 0) ffh mhb052 pxq_x pxq_x d1_x (7 to 0) llc 00h sav cb y cr 00h y y ffh 00h 00h eav cr
1998 apr 09 60 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 52 protection bits bit number function fixed 1 f v h p 3 p 2 p 1 p 0 711111111 600001101 500110011 401010101 301100110 201011010 100111100 001101001 7.8.5 s ynchronization signals horizontal, vertical and frame synchronization signals are either carried beside the data stream on the extra sync pins of dd1 (one pair of sync pins per d1 channel) or are encoded as sav and eav in the 8-bit wide video signal stream. for the 16-bit wide yuv stream sync signals are always available on separate pins. for d1 video inputs the saa7146a is programmed to determine where to recover the synchronization information (from the dedicated sync pins or from the encoded sav and eav codes in the data stream). for d1 video outputs, the saa7146a can be programmed to deliver synchronization information both in sav and eav codes as well as on the dedicated sync pins. non-standard rastered video signals are supported by sync signals at the dedicated sync pins as well as via sav and eav codes. the number of clock cycles, pixels per line and lines per field can be non-standard. these number can range from 1 up to 4095. the signal at the hs pin can perform the following functions: hs: input only, the rising edge is selected to act as timing reference href: input only, gated with cref, the rising edge is selected as timing reference hgt: i/o, high during active video act input only: high during active video, inactive during horizontal and vertical blanking hgt and act: envelope all active pixels (there is no active pixel outside hgt or act), but may also include clock cycles marked as not valid pixels by means of pxq. the vertical sync signal can perform the following functions: vs: input only positive or negative, one edge is selected as timing reference: C if selected edge of vs and selected edge of hs are in phase, then begin 1st (odd) field C if selected edges of vs and hs are out of phase, then begin 2nd (even) field. v-dmsd: input only, falling (trailing) edge is timing reference: C if falling edge of v-dmsd is in high phase of href, then begin 1st (odd) field C if falling edge of v-dmsd is in low phase of href, then begin 2nd (even) field. vgt: i/o, high during active video, (no holes for horizontal blanking) fs: input only, positive or negative, frame sync, (odd/even), (313/312, 263/262 lines) high in one field, low in the other, changes on full line boundaries only. 7.8.6 f ield detection the fields are detected simultaneously at both d1 sync inputs. the results are available in two status registers.
1998 apr 09 61 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 53 field interval de?nitions for d1 (ccir 656) sav and eav codes; note 1 note 1. signals f and v change state synchronously with the end of active video timing reference code at the beginning of the digital line. 7.8.6.1 field detection control field detection modes: direct mode: fld signal detected from incoming h/v signals, for timing behaviour see fig.11. forced toggle: fld signal regularly synchronized to source, but will never stay more than two fields with the same id. the circuit expects to detect a field change with every vertical reference edge, if the field does not change (field error), the circuit change the field id automatically. if the circuit switch to the wrong sequence i. e. at the beginning of processing, it will be synchronized after one second where no field error has occurred. free toggle: fld signal toggles with every vertical reference edge, independent of source fid. definition 625 lines 525 lines v-digital ?eld blanking field 1; start (v = 1) line 624 line 1 field 1; ?nish (v = 0) line 23 line 10 field 2; start (v = 1) line 311 line 264 field 2; ?nish (v = 0) line 336 line 273 f-digital ?eld identi?cation field 1; f = 0 line 1 line 4 field 2; f = 1 line 313 line 266 fig.12 timing of field detection even-to-odd for direct mode. handbook, full pagewidth vs mhb053 hs v-dmsd llc fld-dmsd fld
1998 apr 09 62 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.8.7 a cquisition control the processing window for the scaling unit is defined in the acquisition control. the internal counters (one for the hps and one for the brs) receives programmable values for offset (hxo11 to hxo0, hyo11 to hyo0 and bxo9 to bxo0, byo9 to byo0) and length (numlines, numbytes). these counters are reset by the corresponding sync reference input signal. the horizontal counter increments in qualified pixels for the hps and qualified bytes for the brs, the vertical counter increments in qualified lines, i.e. lines containing at least one qualified pixel. in order to avoid programming dependent line drop effects, the horizontal offset value must not exceed the number of pixels per line. in order to avoid programming dependent field drop effects, the vertical offset value must not exceed the number of lines per field. the acquisition provides the possibility to re-program the vertical offset after the previous job is done (eow at the hps and brs is reached). thus multiple windows can be opened during one field. fig.13 timing of field detection odd-to-even for direct mode. handbook, full pagewidth vs mhb054 hs v-dmsd llc fld-dmsd fld
1998 apr 09 63 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.8.8 c omparison between ccir 656 line and source line counter this section describes how to choose the vertical offset and how to use the source line counter event for rps programming for capturing the expected line. the internal source line counter (slc) is reset by the selected edge of the vertical sync signal which is provided at port vs_x. the falling and rising edges of this signal are selected by the sync_x bits in the initial settings dd1 port register (offset = 50h). consequently, the behaviour of the slc depends on the connected vertical sync signal so that different offsets must be selected to capture the expected line. the active video begins in the ccir 656 line 23 of the video signal; table 54 lists the different offsets which must be selected to capture the expected line. the subsequent diagrams and tables illustrate the relationship between the different vertical sync signals of the pal and ntsc standards, the odd and even field and the internal slc. (1) lq = qualified lines, i.e. lines containing at least one qualified pixel. fig.14 reference signals for scaling window. handbook, full pagewidth mhb055 line hs_x pxq_x vs_x lq (1) active video window numbytes numlines hxo bxo hyo byo scaling window field/ frame
1998 apr 09 64 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 54 offsets to ccir 656 line 23 depending on pal or ntsc source (in compliance with recommendation 601), odd and even ?eld and select mode (see note 1) notes 1. line numbers in parenthesis refer to even field counting. 2. sync signal slc with sav/eav detection (50h, sync_x = 7). 3. sync signal slc with external field identification signal (50h, sync_x = 6). 4. sync signal slc with detection on the falling edge of the vertical sync signal (50h, sync_x = 1, 3 or 5). 5. sync signal slc with detection on the rising edge of the vertical sync signal. for philips devices, the rising edge does not include field information, this information is only defined at the falling edge of the vs signal (50h, sync_x = 0, 2 or 4). 7.8.8.1 video with pal format pal ntsc slc (2) sav/eav slc ext. (3) fs slc (4) falling vs slc (5) rising vs slc sav/eav slc ext. fs slc falling vs slc rising vs 24 (25) 18h (19h) 15 (16) 0fh (10h) 15h (16) 0fh (10h) 21 (22) 15h (16h) 22 (22) 16h (16h) 12 (13)) 0ch (0dh) 12 (13) 0ch (0dh) 18 (19) 12h (13h) fig.15 output timing of saa711x, 50 hz, lines 621 to 8. handbook, full pagewidth mhb057 320 (7) 321 (8) 318 (5) 319 (6) 316 (3) 317 (4) 314 (1) 313 (313) 312 (312) 311 (311) 310 (310) 309 (309) 308 (1) (308) (2) 315 (2) fid ccir 656 vs ccir 656 odd saa711x vs saa711x lines (1) the line numbers not in parenthesis refer to ccir counting. (2) the line numbers in parenthesis refer to single field counting.
1998 apr 09 65 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a fig.16 output timing of saa711x, 50 hz, lines 308 to 321. handbook, full pagewidth mhb056 7 (7) 8 (8) 5 (5) 6 (6) 3 (3) 4 (4) 1 (1) 625 (312) 624 (311) 623 (310) 622 (309) 621 (1) (308) (2) 2 (2) fid ccir 656 vs ccir 656 odd saa711x vs saa711x lines (1) the line numbers not in parenthesis refer to ccir counting. (2) the line numbers in parenthesis refer to single field counting.
1998 apr 09 66 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a this text is here in white to force landscape pages to be rotated correctly when browsing through the pdf in the acrobat reader .this text is here in _ white to force landscape pages to be rotated correctly when browsing through the pdf in the acrobat reader.this text is here in this text is here in white to force landscape pages to be rotated correctly when browsing through the pdf in the acrobat reader. white to force land scape pages to be ... table 55 comparison between ccir 656 lines and the slc (note 1) notes 1. line numbers in parenthesis refer to even field counting. 2. ccir 656 (d1) line. 3. slc with sav/eav detection (50h, sync_x = 7). 4. slc with external field identification signal (50h, sync_x = 6). 5. slc with detection on the falling edge of the vertical sync signal (50h, sync_x = 1, 3 or 5). 6. slc with detection on the rising edge of the vertical sync signal. for philips devices, the rising edge does not include fiel d information, this information is only defined at the falling edge of the vs signal (50h, sync_x = 0, 2 or 4). ccir 656 (d1) line (2) (612) 310 (622) 311 (624) 312 (625) 313 1 (314) 2 (315) 3 (316) 4 (317) 5 (318) 6 (319) 7 (320) 8 (321) 9 (322) 10 (323) 11 (324) 12 (325) 13 (326) 14 (328) 15 (329) slc (3) sav/eav 311 (313) 312 (1) 1 (2) 2 (3) 3 (4) 4 (5) 5 (6) 6 (7) 7 (8) 8 (9) 9 (10) 10 (11) 11 (12) 12 (13) 13 (14) 14 (15) 15 (16) 16 (17) 17 (18) slc ext. fs (4) 302 (304) 303 (305) 304 (306) 305 (307) 306 (308) 307 (309) 308 (310) 309 (311) 310 (312) 311 (313) 312 (1) 1 (2) 2 (3) 3 (4) 4 (5) 5 (6) 6 (7) 7 (8) 8 (9) slc falling vs (5) 302 (304) 303 (305) 304 (306) 305 (307) 306 (308) 307 (309) 308 (310) 309 (311) 310 (312) 311 (313) 312 (1) 1 (2) 2 (3) 3 (4) 4 (5) 5 (6) 6 (7) 7 (8) 8 (9) slc rising vs (6) 308 (310) 309 (311) 310 (312) 311 (313) 312 (1) 1 (2) 2 (3) 3 (4) 4 (5) 5 (6) 6 (7) 7 (8) 8 (9) 9 (10) 10 (11) 11 (12) 12 (13) 13 (14) 14 (15)
1998 apr 09 67 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.8.8.2 video with ntsc format fig.17 output timing of saa711x, 60 hz, lines 523 to 11. handbook, full pagewidth mhb058 10 (10) 11 (11) 8 (8) 9 (9) 6 (6) 7 (7) 4 (4) 3 (3) 2 (2) 1 (1) 525 (262) 524 (261) 523 (1) (260) (2) 5 (5) fid ccir 656 vs ccir 656 odd saa711x vs saa711x lines (1) the line numbers not in parenthesis refer to ccir counting. (2) the line numbers in parenthesis refer to single field counting. fig.18 output timing of saa711x, 60 hz, lines 261 to 274. handbook, full pagewidth mhb059 273 (10) 274 (11) 271 (8) 272 (9) 269 (6) 270 (7) 267 (4) 266 (3) 265 (2) 264 (1) 263 (263) 262 (262) 261 (1) (261) (2) 268 (5) fid ccir 656 vs ccir 656 odd saa711x vs saa711x lines (1) the line numbers not in parenthesis refer to ccir counting. (2) the line numbers in parenthesis refer to single field counting.
1998 apr 09 68 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a this text is here in white to force landscape pages to be rotated correctly when browsing through the pdf in the acrobat reader .this text is here in _ white to force landscape pages to be rotated correctly when browsing through the pdf in the acrobat reader.this text is here in this text is here in white to force landscape pages to be rotated correctly when browsing through the pdf in the acrobat reader. white to force land scape pages to be ... table 56 comparison between ccir 656 lines and slc (note 1) notes 1. line numbers in parenthesis refer to even field counting. 2. ccir 656 (d1) line. 3. slc with sav/eav detection (50h, sync_x = 7). 4. slc with external field identification signal (50h, sync_x = 6). 5. slc with detection on the falling edge of the vertical sync signal (50h, sync_x = 1, 3 or 5). 6. slc with detection on the rising edge of the vertical sync signal. for philips devices, the rising edge does not include fiel d information, this information is only defined at the falling edge of the vs signal (50h, sync_x = 0, 2 or 4). ccir 656 (d1) line (2) (525) 262 1 (264) 2 (265) 3 (266) 4 (267) 5 (268) 6 (269) 7 (270) 8 (271) 9 (272) 10 (273) 11 (274) 12 (275) 13 (276) 14 (277) 15 (278) 16 (279) 17 (280) 18 (281) slc sav/eav (3) 262 (263) 1 (1) 2 (2) 3 (3) 4 (4) 5 (5) 6 (6) 7 (7) 8 (8) 9 (9) 10 (10) 11 (11) 12 (12) 13 (13) 14 (14) 15 (15) 16 (16) 17 (17) 18 (18) slc ext. fs (4) 252 (251) 253 (252) 254 (253) 255 (254) 256 (255) 257 (256) 258 (257) 259 (258) 260 (259) 261 (260) 262 (261) 1 (262) 2 (263) 3 (1) 4 (2) 5 (3) 6 (4) 7 (5) 8 (6) slc falling vs (5) 252 (251) 253 (252) 254 (253) 255 (254) 256 (255) 257 (256) 258 (257) 259 (258) 260 (259) 261 (260) 262 (261) 1 (262) 2 (263) 3 (1) 4 (2) 5 (3) 6 (4) 7 (5) 8 (6) slc rising vs (6) 258 (260) 259 (261) 260 (262) 261 (263) 262 (1) 1 (2) 2 (3) 3 (4) 4 (5) 5 (6) 6 (7) 7 (8) 8 (9) 9 (10) 10 (11) 11 (12) 12 (13) 13 (14) 14 (15)
1998 apr 09 69 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.9 high performance scaler (hps) depending on the selected port modes the incoming and scaled data are formatted/reformatted (8-bit or 16-bit), and the corresponding reference signals are generated. based on these reference signals the active processing window is defined in a versatile way via programming. the programming register can be loaded during the processing of the previous field, frame or line by rps. in this way each d1 port gets processed in a field or frame alternating manner. if the incoming signals are not locked, then the acquisition is waiting for the new active video of the subsequent field. the corresponding fields are detected by a field detection. to support asynchronous video processing in the two video paths, each d1 port has its own field detection. the video signal source is also source for the qualify signal pxq. before being processed in the central scaling unit the incoming data passes to the bcs control unit, where monitor control functions for adjusting brightness and contrast (luminance) as well as saturation (chrominance) are implemented (bcs control). the horizontal scaling is carried out in two steps; a prefiltering (bandwidth limitation for initialising) and a horizontal fine scaling. between them the vertical processing is performed. 7.9.1 bcs control the parameters for brightness, contrast and saturation can be adjusted in the bcs control unit. the luminance signal can be controlled by the bits brig7 to brig0 and cont6 to cont0. the chrominance signal can be controlled by the bits sat6 to sat0. brightness control (brig7 to brig0): 00h; minimum offset 80h; ccir level ffh; maximum offset. contrast control (cont6 to cont0): 00h; luminance off 40h; ccir level 7fh; 1.9999 amplitude. saturation control (sat6 to sat0): 00h; colour off 40h; ccir level 7fh; 1.9999 amplitude. limits: all resulting output values are limited to minimum (equals 0) and maximum (equals 255). 7.9.2 s caling unit the scaling to a randomly sized window is performed in three steps: horizontal prescaling (bandwidth limitation for anti-aliasing, via fir prefiltering and subsampling) vertical scaling (generating phase interpolated or vertically low-passed lines) horizontal phase scaling (phase correct scaling to the new geometric relations). the scaling process generates a new pixel/clock qualifier sequence. there are restrictions in the combination of input sample rate and up or downscaling mode and scaling factor. the maximum resulting output sample rate at the dd1 port is 1 2 llc, because of compliance to the ccir 656 format. 7.9.2.1 horizontal prescaling the incoming pixels in the selected range are pre-processed in the horizontal prescaler (first stage of the scaling unit). it consists of a fir prefilter and a pixel collecting subsampler. 7.9.2.2 fir pre?lter the video components y, u and v are fir pre-filtered to reduce the signal bandwidth according to the downscale for factors between 1 and 1 2 , so that aliasing, due to signal bandwidth expansion, is reduced. the prefilter consists of 3 filter stages. the transfer functions are listed in the section 7.12. the prefilter is controlled by the scaler register bits pfy3 to pfy0 and pfuv3 to pfuv0 in the hps horizontal prescale register (see table 79). figures 19 and 20 show frequency response characteristics and the corresponding scaler register settings. the prefilter operates on yuv 4:4:4 data. as u and v are generated by simple chroma pixel doubling, the uv prefilter should also be used to generate the interpolated chroma values. 7.9.2.3 subsampler to improve the scaling performance for scales less than 1 2 down to icon size, a fir filtering subsampler is available. it performs a subsampling of the incoming data by a factor of 1/n, where n = 1 to 64. this operation is controlled by xpsc, where n = xpsc + 1. where nip = number of input pixels/line and nop = number of desired output pixels/line, the basic equation to calculate xpsc is: xpsc = trunc [(nip/nop) - 1]
1998 apr 09 70 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a the subsampler collects a number of [xpsc + 2 - xacm] pixels to calculate a new subsampled output pixel. so a downscale dependent fir filter is built with up to 65 taps which reduces anti-aliasing for small sizes. if xacm = 0, the collecting sequence overlaps which means that the last pixel of sequence m is also the first pixel of sequence m+1. to implement a real subsampler bypass, xacm has to be set to logic 1. as the phase correct horizontal fine scaling is limited to a maximum downscale of 1 4 , this circuitry has to be used for downscales less than 1 4 of the incoming pixel count. to get unity gain at the subsamplers output for all subsampling ratios, the scaler register parameters cxy, cxuv and dcgx have to be used. in addition, this can be used to modify the fir characteristic of the subsampler slightly. table 57 illustrates examples for scaler register settings, depending on a given prescale ratio. referring to table 57(divider in column weight sum) it should be noted that an internal xpsc depending automatic prenormalization is valid for: xpsc > 8, > 16, > 32, which reduces the input signal quantization. in addition it should be noted that for xpsc 3 15 the lsb of the cxy,cxuv parameter becomes valid. fig.19 luminance prefilter: frequency response for miscellaneous register settings. handbook, full pagewidth mgg263 0 0.5 18 - 12 - 18 - 24 - 30 - 36 - 6 - 42 0 6 12 db 0.1 0.2 0.3 0.4 mhz 0001 0010 0011 1011 1111 pfy3 to pfy0
1998 apr 09 71 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 57 horizontal prescaling and normalization horizontal prescaler xpsc coefficient sequence (example) cxy (luminance) cxuv (chroma) weight sum dcgx bcs (contr. | sat.) = x/y 64 1 0 1-1 0 0 2 1 1 1 2 1 1-1-1 0 0 3 1 2 3 1-2-1 0 2 4 2 1 1 3 2 1-1-1-1 0 0 4 2 1 1 4 3 1-1-1-1-1 0 0 5 2 4 5 1-2-2-2-1 0 6 8 3 1 1 5 4 111 111 0 0 6 2 4 6 121 121 0 2 8 3 1 112 211 0 4 8 3 1 1 6 5 1111111 00 7 3 8 7 1112111 08 8 3 1 1 7 6 1111 1111 0 0 8 3 1 1 8 7 1111 1 1111 0 0 9 3 8 9 1222 2 2221 1 e 16 7 1 fig.20 chrominance prefilter: frequency response for miscellaneous register settings. handbook, full pagewidth mgg264 0 0.5 18 - 12 - 18 - 24 - 30 - 36 - 6 - 42 0 6 12 db 0.1 0.2 0.3 0.4 mhz 0001 0010 0011 1111 1010 1110 pfuv3 to pfuv0
1998 apr 09 72 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 1 9 8 1111111111 00 10/ 2 2 8 10 1221 2 2 1221 1 6 16/ 2 31 1122 2 2 2211 1 c 16/ 2 31 1 10 9 1111 1 1 1 1111 0 0 11/ 2 2 8 11 1212 1 2 1 2121 2 a 16/ 2 31 11122222111 38 16/ 2 31 1 11 10 1111 11 11 1111 0 0 12/ 2 2 8 12 1211 21 12 1121 1 2 16/ 2 31 1111 22 22 1111 3 0 16/ 2 31 1 12 10 1111 11 1 11 1111 0 0 13/ 2 2 8 13 1121 11 2 11 1211 4 4 16/ 2 31 1111122211111 60 16/ 2 31 1 13 10 1111 111 111 1111 0 0 14/ 2 2 8 14 1111 211 112 1111 1 0 16/ 2 31 1111 112 211 1111 4 0 16/ 2 31 1 14 10 1111 111 1 111 1111 0 0 15/ 2 2 8 15 1111 111 2 111 1111 8 0 16/ 2 31 1 15 14 1111 1111 1111 1111 0 0 16/ 2 31 1 16 15 1111 1111 1 1111 1111 - 17/ 2 3 16 17 1222 2222 2 2222 2221 f f 32/ 2 71 1 17 16 1111 1111 1 1 1111 1111 0 0 18/ 4 2 16 18 1222 2222 1 1 2222 2221 f e 32/ 4 31 1222 2122 22 2212 2221 d f 32/ 4 31 1 18 17 1111 1111 1 1 1 1111 1111 0 0 19/ 4 2 16 19 1222 1222 1 2 1 2221 2221 e e 32/ 4 31 1222 211 22222112 2221 9 f 32/ 4 31 -- - - xx/ 4 -- 1 33 32 1111...1111 0 0 34/ 8 2 - -- - - xx/ 8 -- 1 63 62 ----- 1 64 63 ----- horizontal prescaler xpsc coefficient sequence (example) cxy (luminance) cxuv (chroma) weight sum dcgx bcs (contr. | sat.) = x/y 64
1998 apr 09 73 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.9.2.4 vertical scaler the vertical scaler performs the vertical downscaling of the input data stream to a randomly number of output lines. it can be used for input line lengths up to 768 pixels/line and has to be bypassed, if the input line length exceeds this pixel count. for the vertical scaling there are two different modes: the accu mode (vertical accumulation) for scales down to icon size and the linear phase interpolation (lpi) mode for scales between 1 and 1 2 . 7.9.2.5 accu mode (scaling factor range 1 to 1/1024; yacm = 1) for vertical scales down to icon size the accu mode can be used. in this mode the parameter ysci controls the scaling and the parameter yacl the vertical anti-aliasing filtering. the output lines are generated by a scale-dependent variable averaging of (yacl + 2) input lines. in this way a vertical fir filter is build for anti-aliasing, with up to maximum 65 taps. ysci defines the output line qualifier pattern and yacl defines the sequence length for the line averaging. for accurate processing the sequence has to fit into the qualifying pattern. in case of misprogramming yacl, unexpected line dropping occurs. where: n ol = number of output lines and n il = number of input lines. the ysci (scaling increment), yacl (accumulation length; optimum: 1 line overlap) and yp (scaling start phase) have to be set according to the equations below, see fig.21. yacl = trunc [n il /n ol - 1] accumulation sequence length; i.e. number of lines per sequence, that are not part of overlay region of neighbouring sequences (optimum: 1 line overlapped) ysci = int [1024 (1 - n ol /n il )] scaling increment ypx = int [ysci/16] scaling start phase (fix; modified in lpi mode only). in order to get a unity amplitude gain for all sequence lengths and to improve the vertical scaling performance, the accumulated lines can be weighted and the amplitude of the scaled output signal has to be renormalized. in the given example (see fig.21), using the optimal weighting, the gain of a sequence results in 1 + 2 + 2 + 1 = 6. renormalization (factor 1 6 ) can be done by gain reduction using bcs control (brightness, contrast, saturation) down to 4 6 and selecting factor 1 4 for dcgy2 to dcgy0 which may result in a loss of signal quantization, or by gain emphasizing using bcs control up to 8 6 and selecting factor 1 8 for dcgy2 to dcgy0 which may result in a loss of signal detail due to limiting in the bcs control. normally, the weighting would be 2 + 2 + 2 + 2. in this case the gain can be renormalized simply with dcgy2 to dcgy0 = 010 (factor 1 8 ). table 58 gives examples for register settings depending on a given scale ratio. fig.21 example: vertical accumulation. handbook, full pagewidth mgd697 1st sequence scaling factor s = 1/3: vertical accumulation of 4 lines (1 line overlap) optimal weighting factors: line 1 1 2 2 1 2 2 1 2 2 1 line 2 2nd sequence 3rd sequence yacl = int {(1 - s)/s} ysci = int {1024 (1 - s)} yp x = int {ysci/16} = 2 (dotted lines) = 682 = 42
1998 apr 09 74 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 58 vertical scaling and normalization vertical scale ratio yacl coefficient sequence (example) cya; cyb weight sum dcgy bcs (contr. | sat.) = x/y 64 1to 1 2 (0) 0 1-1 01, 00 2 0 1 1 2 to 1 3 (512) 1 1-1-1 03, 00 3 0 2 3 1-2-1 01, 02 4 1 1 1 3 to 1 4 (683) 2 1-1-1-1 03, 00 4 1 1 1 4 to 1 5 (768) 3 1-1-1-1-1 07, 00 5 1 4 5 1-2-2-2-1 01, 06 8 2 1 1 5 to 1 6 (820) 4 111 111 07, 00 6 1 4 6 121 121 05, 02 8 2 1 112 211 03, 04 8 2 1 1 6 to 1 7 (854) 5 1111111 0f,00 7 2 8 7 111 2 111 07, 08 8 2 1 1 7 to 1 8 (878) 6 1111 1111 0f, 00 8 2 1 1 8 to 1 9 (896) 7 111111111 1f,00 9 2 8 9 1222 2 2221 01, 1e 16 3 1 1 9 to 1 10 (911) 8 1111 1 1 1111 1f, 00 10 3 8 10 2121 2 2 1212 09, 15 16 3 1 1122 2 2 2211 03, 1c 16 3 1 1 10 to 1 11 (922) 9 11111111111 3f,00 11 2 8 11 1212 1 2 1 2121 15, 2a 16 3 1 11122222111 07,38 16 3 1 1 11 to 1 12 (931) 10 1111 11 11 1111 3f, 00 12 2 8 12 1211 21 12 1121 2d, 12 16 3 1 1111 22 22 1111 0f, 30 16 3 1 1 12 to 1 13 (939) 11 1111111111111 7f,00 13 2 8 13 1111212121111 2f,50 16 3 1 1121 11 2 11 1211 3b, 44 16 3 1 1 13 to 1 14 (946) 12 1111 111 111 1111 7f, 00 14 2 8 14 1111 211 112 1111 6f, 10 16 3 1 1111 112 211 1111 3f, 40 16 3 1 1 14 to 1 15 (951) 13 1111 111 1 111 1111 ff, 00 15 2 8 15 1111 111 2 111 1111 7f, 80 16 3 1 1 15 to 1 16 (956) 14 1111 1111 1111 1111 ff, 00 16 3 1 1 16 to 1 17 (960) 15 1111 1111 1 1111 1111 ff, 00 17 3 16 17 2122 2222 2 2222 2212 02, fd 32 4 1
1998 apr 09 75 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 1 17 to 1 18 (964) 16 1111 1111 1 1 1111 1111 ff, 00 18 3 16 18 2212 2212 2 2 2122 2122 44, bb 32 4 1 1222 2222 1 1 2222 2221 01, fe 32 4 1 ... ... ... ... ... ... ... 1 23 to 1 24 (980) 22 1111 2222 1111 1111 2222 1111 0f, f0 32 4 1 1121 1212 1121 1211 2121 1211 ad, 52 32 4 1 vertical scale ratio yacl coefficient sequence (example) cya; cyb weight sum dcgy bcs (contr. | sat.) = x/y 64 7.9.2.6 lpi mode (scaling factor range 1 to 1 2 ; register bit yacm = 0) to preserve the signal quality for slight vertical downscales (scaling factors 1 to 1 2 ) linear phase interpolation (lpi) between consecutive lines is implemented to generate geometrically correct vertical output lines. thus, the new geometric position between lines n and n + 1 can be calculated. a new output line is calculated by weighting the samples p of lines n and n + 1 with the normalized distance to the newly calculated position: p(m) = a p(n + 1) + (1 - a) p(n); where a = 0 to 63 64 . with n ol = number of output lines and n il = number of input lines the scaler register bits ysci (scaling increment) and yp (scaling start phase) have to be set according to the following equations: ysci = int [1024 (n il /(n ol - 1)] scaling increment ypx = int [ ysci 16 ] scaling start phase (recommended value). fig.22 calculation of output lines. handbook, halfpage mhb107 n distance = 1 n + 1 i i i m i a (1 - a) input lines new calculated position line of output line m the vertical start phase offset is defined by yp 64 (yp=0to 64): yp = 0: offset = 0 geometrical position of 1st line out = 1st line in yp = 64: offset = 64 64 = 1 geometrical position of 1st line out = 2nd line in . finally 3 special modes are to be emphasized: 1. bypass (ysci = 0, yp = 64); each line out is equivalent to corresponding line in 2. low-pass (ysci = 0, yp < 64); e.g. yp = 32: average value of 2 lines (1 + z - h filter) 3. for processing of interlaced input signals the lpi mode must be used (accu mode would cause line pairing problems). the scaling start phase for odd and even field have to be set to: yp even = 3 2 yp odd (line 1 = odd) in modes 1 and 2 the first input line is fed to the output (without processing), so that the number of output lines equals the number of input lines 7.9.2.7 flip option (mirror = 1) for both vertical scaling modes there is a flip option mirroring available for input lines with a maximum of 384 pixels. in the case of full screen pictures (e.g. 768 576) that have to be flipped, they first have to be downscaled to 384 pixel/line in the horizontal prescaling unit and after vertical processing (flipping) they may be rezoomed to the original 768 pixels/line in the following vpd. it should be noted that, when using the flip option, the last input line can not be displayed at the output.
1998 apr 09 76 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.9.3 h orizontal phase scaling in the phase correct horizontal phase scaling (hps) the pixels are calculated for the geometrically correct, orthogonal output pattern, down to 1 4 of the prescaled pattern. a horizontal zooming feature is also supported. the maximum zooming factor is at least 2, even more dependent on input pattern and prescaling settings. the phase scaling consists of a filter and an arithmetic structure which is able to generate a phase correct new pixel value almost without phase or amplitude artefacts. the required sample phase information is generated by a sample phase calculator, with an accuracy of 1 64 of the pixel distance. the up/downscaling with this circuitry is controlled by the scaler register parameters xsci and xp. as the fine scaling is restricted to downscales > ( 1 4 of the fine scalers input pixel count), xsci is also a function of the prescaling parameter xpsc. with n ip = number of input pixel/line (at dd1 input) and n op = number of desired output pixels/line, xsci is defined to: xsci = int [(n ip /n op ) 1024/(xpsc + 1)] the maximum value of xsci = 4095. zooming is performed for xsci values less than 1024. the number of disqualified clock cycles between consecutive pixel qualifiers (at the fine scalers input) defines the maximum possible zoom factor. consequently, zooming may also be a function of xpsc. it should be noted that if the zooming factor is greater than 2, some artefacts may occur at the end of the zoomed line. 7.9.4 c olour s pace m atrix (csm), dither and g - correction the scaled yuv output data is converted after interpolation into rgb data according to ccir 601 recommendations. the csm is bypassed in all yuv formats or monochrome modes. the matrix equations considering the digital quantization are: r = y + 1.375v g=y - 0.703125v - 0.34375u b = y + 1.734375u. a dither algorithm is implemented for error diffusion. rom tables are implemented at the matrix output to provide anti-gamma correction of the rgb data. a curve for a gamma of 1.4 is implemented. the tables can be used to compensate gamma correction for linear data representation of rgb output data. the chroma signal key generates an alpha signal used in several rgb formats. therefore, the processed uv data amplitudes are compared with thresholds. a logic 1 is generated, if the amplitude is within the specified amplitude range. otherwise a logic 0 is generated. keying can be switched off by setting the lower limit higher than the upper limit! 7.10 binary ratio scaler (brs) 7.10.1 g eneral description the brs is the second scaler in the saa7146a. the brs is supposed to support different encoder applications while the hps is processing video data. the brs does not support clipping. the mainstream application of the brs is to read data via pci, e.g. a qcif-formatted video data to proceed with horizontal and vertical upscaling to cif-format and place it at the encoders disposal (normal playback mode). to support ccir encoder and square pixel encoder, an active video window as input for the brs can be defined. it will prevent black pixels being displayed at the end of the line or at the bottom of the field. the brs supports only the yuv 4:2:2 video data format (see section 7.11.2). the used dd1 i/o data format is 8-bit. the brs uses video dma channel 3 (fifo 3) which is only available, if the hps is not in planar mode or writes back clip information. vertical upscaling is supported by means of repeated reading of the same line via pci. vertical downscaling is achieved by line dropping. horizontal downscaling is performed by an accumulating fir filter. the downscaling is available for the inbound mode and the upscaling is available for the outbound mode (see figs 23 and 24). vertical ratios: 4, 2, 1, 1 2 and 1 4 ; select with brs_v horizontal ratios: 8, 4, 2, 1, 1 2 , 1 4 and 1 8 ; select with brs_h. if the data is sent from dd1 to pci, the processing window for the brs scaling unit is defined in the acquisition control (see section 7.8.7).
1998 apr 09 77 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a fig.23 brs inbound mode. handbook, full pagewidth mhb060 vertical downscaling pci (dma3) 1/2 1/2 1/4 1/8 1 1/4 1 line dropping accumulating fir horizontal d1 fig.24 brs outbound mode. handbook, full pagewidth mhb061 vertical upscaling pci (dma3) 4 2 8 4 2 1 1 line repetition linear interpolation horizontal d1
1998 apr 09 78 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a the pci source data is defined by the base address (baseodd3 and baseeven3), the distance between the start addresses of two consecutive lines of a field (pitch3), the number of lines per field of the source frame (numlines3) and the number of bytes per line of the source frame (numbyte3). the programmer must provide correct scaling settings to fulfil the target window requirements. the pitch has to be dword aligned. 7.10.2 p layback mode the saa7146a offers three different modes to support the playback mode for various systems. the binary ratio scaler (brs) inputs data from fifo 3, therefore the dma3 is in master read operation. the scaling result is passed to the dd1 output. the following sections describe the three different modes: field memory mode, direct mode and line memory mode. 7.10.2.1 field memory mode in the field memory mode the saa7146a takes a vertical sync signal as a timing reference signal. a reset signal for a field memory and a pxq as write enable are generated within the circuit and both are sent to port a or port b. in this mode the pixel clock depends on the pci load. the pixels are provided to the dd1 port with maximum 1 2 llc (ccir 656), the picture rate is restricted by the vertical timing reference. since the transfer works without losing any data the pixel clock can be varied, therefore an external field memory is needed at the dd1 interface. the saa7146a writes its data continuously to this memory. the video window size depends on the selected window size in the system memory, the frame buffer (numlines, numbytes, pitch and base address) and the selected scaling ratio. fig.25 sync and data path for field memory mode. handbook, full pagewidth mgg266 dma read data data fifo empty pxq (write enable) field reset pxq fifo3 dword request pci brs data vs llc d1 interface
1998 apr 09 79 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a fig.26 reference signals for scaling window for direct and line memory mode. handbook, full pagewidth mgg265 line hs pxq (only in direct mode) vs active video window (numbytes/2) scale ratio numlines scale ratio bxo byo scaling result window field/ frame 7.10.2.2 direct mode the timing reference signals (vs, hs, llc and fid) are taken from port a or port b. the brs has to deliver pixel with pixel clock of 1 2 llc to the d1 port. to ensure that there are no dropouts, a simple underflow handling is performed by the dma read module. if the pci load is big and a fifo underflow occurs, the dma read module uses a grey value (10h for luminance, 80h for chrominance) or the last pixel as a substitute. the fifo control counts the failed requests and removes the late values from the fifo hoping to catch up for lost time to the end of a line. at the end of a line given by the external source the dma tries to read the data of the new line. this time is defined by the horizontal offset (bxo) of the input acquisition, see fig.26. the pxq can be used as key signal for the on screen display (osd) data to support panning, if the video window has no full screen format. 7.10.2.3 line memory mode the timing reference signals (vs, hs, llc and fid) are taken from port a or port b. the access time could be extended by using a line memory at the d1 interface. if a fifo underflow occurs during the active processing, the dma read unit waits for the next valid data hoping to catch up for the lost time during the horizontal blanking interval. the timing is retriggered by the h-sync and v-sync. therefore it is possible, depending on the pci load, that a line or a part of a line is read multiple from the line memory. the pxq is used as a write enable signal (see fig.27).
1998 apr 09 80 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a fig.27 sync and data path for direct and line memory mode. handbook, full pagewidth mgg268 dma read data data fifo empty pxq (write enable in line memory mode) pxq fifo3 dword request pci brs data vs hs llc d1 interface 7.10.3 vbi data interface the saa7146a transports vbi data (data during the vertical blanking interval) or vbi test signals between real time world and the computer system. the data can be in yuv format, luminance y only, encoded digital cvbs on luminance channel or a single bit stream of sliced data. 1 or 2 msb of y is utilized to carry data bit. pxq pixel qualifier is used as data clock. 7.11 video data formats on the pci-bus the big/little-endian is supported in the way that a 2 and a 4-byte swapping is possible. the data formats using 32 bits per pixel requires a 4-byte swap, whereas the data formats using 16 bits per pixel requires a 2-byte swap. 7.11.1 s caler output formats (hps) 7.11.1.1 rgb rgb each defined as full range, all bits = 0 for black and all bits = 1 for white. all rgb formats are composed formats and use video fifo 1 and video dma channel 1. a rgb-32: the a rgb format use a full byte for each colour component and one byte for the colour key information. the bytes are packed cyclicly into dwords and uses one dword per sample. a can be the colour key bit in all 8 bits or read via fifo 2 (see section 7.11.1.3) and uses one entire dword per sample (see table 59). rgb-24 packed: the 24-bit rgb format use a full byte for each colour component. the bytes are packed cyclicly into dwords, uses 0.75 dwords per sample, i.e. 3 dwords per 4 samples. the byte phase of the first sample on each line is defined by the 2 lsbs of the dma base (see table 60).
1998 apr 09 81 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 59 a rgb-32 format table 60 rgb-24 packed format packing within 32-bit dword bit 31 to bit 24 bit 23 to bit 16 bit 15 to bit 8 bit 7 to bit 0 a / - rgb a / - vyu bus cycle packing within 32-bit dword bit 31 to bit 24 bit 23 to bit 16 bit 15 to bit 8 bit 7 to bit 0 1b 1 r 0 g 0 b 0 2g 2 b 2 r 1 g 1 3r 3 g 3 b 3 r 2 the following formats use two pixels per dword and derive rgb from rgb-24 by truncation or by error diffusion dither. the byte phase of the first sample each line is defined by lsb + 1 of dma base. a is the colour key. rgb-16 ( 5:6: 5): red has 5 bits, green has 6 bits, blue has 5 bits rgb-15 ( a :5:5:5): a -bit, red has 5 bits, green has 5 bits, blue has 5 bits rgb-15 ( 5:5: a : 5): red has 5 bits, green has 5 bits, a bit, blue has 5 bits. table 61 rgb-16 formats dword packing within 32-bit dword bit 31 to bit 16 bit 15 to bit 0 pixel 1 pixel 0 7.11.1.2 yuv all yuv formats are based on ccir coding: luminance y in straight binary: black: y = 16 of 256 linear coding white: y = 235 of 256 linear coding. colour difference signals uv in offset binary: no colour: u = v = 128 of 256 steps full colour: u = v = 128 112 steps. yuv4:2:2: u and v sampled co-sided with first y sample (of 2 samples in-line). byte phase of the first sample each line is defined by bit 0 and bit 1 of dma base address (see table 62). yuv4:1:1: u and v sampled co-sided with first y sample, (of 4 samples in-line), 8 samples are packed in 3 dwords (see table 63).
1998 apr 09 82 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 62 yuv4:2:2 format table 63 yuv4:1:1 format the following formats are planar yuv formats and use the three video fifos and three video dma channels 1, 2 and 3. the byte phase of the first sample each line is defined by the 2 lsbs of every dma base. yuv4:4:4; uandv sampled with every y sample yuv4:2:2; uandv sampled co-sided with first y sample (of 2 samples in-line) yuv4:2:0; mpeg u and v sampled at upper left sample of 4 sample in square (2 2) yuv-9 video; u and v sampled at selected sample of 16 samples in-square (4 4) yuv1; yuyv, yuyv... yuv2; yyuu, yyvv... 7.11.1.3 8-bit formats y8g ; only y or inverted y a 8 ; 8-bit alpha information, to be master-read through fifo 2 and merged into rgb-24 with alpha. there are two pseudo clut formats, which derives its bits from rgb-24 or yuv-24 by truncation, or by error diffusion dither. the byte phase of the first sample each field is defined by 2 lsbs of dma base. rgb-8 (3 : 3 : 2); red has 3 bits, green has 3 bits, blue has 2 bits yuv8 (4 : 2 : 2); y has 4 bits, u has 2 bits, v has 2 bits. y = 0 doesnt exist, to handle 16-bit colour formats for pseudo clut. after dithering, y min =1. all 8-bit formats are packed formats, 4 samples go into one dword. the byte phase of the first sample of each line is defined by the 2 lsbs of the dma base. all except a 8 use fifo 1. table 64 8-bit formats packing within 32-bit dword bit 31 to bit 24 bit 23 to bit 16 bit 15 to bit 8 bit 7 to bit 0 y 1 v 0 y 0 u 0 bus cycle packing within 32-bit dword bit 31 to bit 24 bit 23 to bit 16 bit 15 to bit 8 bit 7 to bit 0 1y 1 v 0 y 0 u 0 2y 3 v 4 y 2 u 4 3y 7 v 6 y 5 y 4 packing within 32-bit dword bit 31 to bit 24 bit 23 to bit 16 bit 15 to bit 8 bit 7 to bit 0 pixel 3 pixel 2 pixel 1 pixel 0
1998 apr 09 83 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.11.2 b inary ratio scaler output formats all yuv formats are based on ccir coding: luminance y in straight binary: black: y = 16 of 256 linear coding white: y = 235 of 256 linear coding. colour difference signals uv in offset binary: no colour: u = v = 128 of 256 steps full colour: u = v = 128 112 steps. the following formats use video fifo 3, dma channel 3 and are packed formats. yuv4:2:2 uandv sampled co-sided with first y sample (of 2 samples in-line). byte phase of the first sample each line is defined by bit 0 and bit 1 of dma base address. table 65 yuv4:2:2 formats 7.11.2.1 vbi data formats y8; uses only the y portion of the data stream and packs four bytes in one dword yuv4:2:2; packs two pixel into one dword, the order is y 1 ,v 0 ,y 0 ,u 0 1-bit format; the y1 format is a 1-bit format which packs 32 times the most significant bit of luminance (y) into one dword, the first bit is bit 31 of the dword 2-bit format; the y2 format is a 2-bit format which packs 16 times the two most significant bits of luminance (y) into one dword, the first bit is bit 31 of the dword. 7.12 scaler register 7.12.1 i nitial setting of dual d1 interface the initial settings of the dual d1 interface contains all control bits of the scaler part which do not change during a cyclic processing of the video path. these control bits must be initialized at the beginning of the processing. the different upload conditions of the video path depend on these control bits. changing these bits during the active processing can cause a valid upload. packing within 32-bit dword bit 31 to bit 24 bit 23 to bit 16 bit 15 to bit 8 bit 7 to bit 0 y 1 v 0 y 0 u 0
1998 apr 09 84 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 66 initial setting of dual d1 interface offset (hex) name bit type description 50 llc_a 31 rw line locked clock control for d1_a: 0: llc_a set to input 1: llc_a set to output, taken from llc_b sio_a 30 to 29 rw synchronization port_a con?guration: 00: hs_a and vs_a are input (i.e. 3-state) 01: hs_a is output, hgt of hps; vs_a is output, vgt of hps 10: hs_a is output, reset signal for a field memory vs_a is input, vertical sync signal for brs this setting is needed for the field memory mode 11: hs_a is output, hgt of brs; vs_a is output, vgt of brs pvo_a 28 rw polarity of vs_a, if vs output: 0: direct from hps or brs, see sio_a 1: inverted pho_a 27 rw polarity of hs_a, if hs output is select by sio_a: 0: direct from hps or brs, see sio_a 1: inverted 50 sync_a 26 to 24 rw sync edge selection and ?eld detection mode internal sync signals synca (ha, va, fa) if: hs, vs are input: ha/va/fa derived from pins hs, vs are output: hs/vs as select by sio_a 000: ha at rising edge of hs; va at rising edge of vs; fa = hs vs-rising, directly 001: ha at rising edge of hs; va at falling edge of vs; fa = hs vs-falling, directly 010: ha at rising edge of hs; va at rising edge of vs; fa = hs vs-falling, forced toggle 011: ha at rising edge of hs; va at falling edge of vs; fa = hs vs-falling, forced toggle 100: ha at rising edge of hs; va at rising edge of vs; fa = free toggle 101: ha at rising edge of hs; va at falling edge of vs; fa = free toggle 110: ha at rising edge of hs; va at rising and falling edge of frame sync at the vs pin; fa = direct fs 111: ha, va, fa; derived from sav and eav decoded from the data-stream at d1_a port. not used if the msb of hpsdatasel in table 71 is set to logic 1 50 fidesa 23 and 22 rw field identi?cation port_a edge select (odd is de?ned by fid = 1, even is de?ned by fid = 0) 00: no interrupt condition 01: rising edge is interrupt condition 10: falling edge is interrupt condition 11: both edges are interrupt condition - 21 to 16 - reserved
1998 apr 09 85 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 50 llc_b 15 rw line locked clock control for d1_b: 0: llc_b set to input 1: llc_b set to output, taken from llc_a 50 sio_b 14 and 13 rw synchronization port_b con?guration: 00: hs_b and vs_b are input (i.e. 3-state) 01: hs_b is output, hgt of hps; vs_b is output, vgt of hps 10: hs_b is output, reset signal for a field memory; vs_b is input, vertical sync signal for brs this setting is needed for the field memory mode 11: hs_b is output, hgt of brs; vs_b is output, vgt of brs 50 pvo_b 12 rw polarity of vs_b, if vs output: 0: direct from hps or brs, see sio_b 1: inverted 50 pho_b 11 rw polarity of hs_b, if hs output is select by sio_b: 0: direct from hps or brs, see sio_b 1: inverted 50 sync_b 10 to 8 rw sync edge selection and ?eld detection mode internal sync signals syncb (hb, vb and fb) if: hs, vs are input: hb/vb/fb derived from pins hs, vs are output: hs/vs as select by sio_b 000: hb at rising edge of hs; vb at rising edge of vs; fb = hs vs-rising, directly 001: hb at rising edge of hs; vb at falling edge of vs; fb = hs vs-falling, directly 010: hb at rising edge of hs; vb at rising edge of vs; fb = hs vs-falling, forced toggle 011: hb at rising edge of hs; vb at falling edge of vs; fb = hs vs-falling, forced toggle 100: hb at rising edge of hs; vb at rising edge of vs 101: hb at rising edge of hs; vb at falling edge of vs; fb = free toggle 110: hb at rising edge of hs; vb at rising and falling edge of frame sync at the vs pin; fb = direct fs 111: hb, vb and fb derived from sav and eav decoded from the data-stream at d1_b port. not used if the msb of hpsdatasel in table 71 is set to logic 1 50 fidesb 7 and 6 rw field identi?cation port_b edge select (odd is de?ned by fid = 1, even is de?ned by fid = 0) 00: no interrupt condition 01: rising edge is interrupt condition 10: falling edge is interrupt condition 11: both edges are interrupt condition - 5to0 - reserved offset (hex) name bit type description
1998 apr 09 86 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.12.2 v ideo data stream handling at port d1_a table 67 video data stream handling at port d1_a 7.12.3 v ideo data stream handling at port d1_b table 68 video data stream handling at port d1_b offset (hex) name bit type description 54 vid_a 31 and 30 rw video data port_a and pxq_a select (pxq goes always with data): 00: input, i.e. 3-state 01: reserved 10: output data stream is y8c from brs 11: output data stream is y8c from hps y8c_a 29 rw y8c codes, if output y8c only: 0: no sav and eav data in the video data output-stream 1: with sav and eav - 28 and 27 - reserved pfid_a 26 rw polarity change of the ?eld identi?cation signal at port_a: 0: as detected in the field detection 1: inverted - 25 to 16 - reserved offset (hex) name bit type description 54 vid_b 15 and 14 rw video data port_b and pxq_b select (pxq goes always with data): 00: input, i.e. 3-state 01: reserved 10: output data stream is y8c from brs 11: output data stream is y8c from hps y8c_b 13 rw y8c codes: 0: no sav and eav data in the video data output stream 1: with sav and eav - 12 and 11 - reserved pfid_b 10 rw polarity change of the ?eld identi?cation signal at port_b 0: as detected in the field detection 1: inverted - 9to0 - reserved
1998 apr 09 87 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.12.4 brs p rogramming r egister the brs programming has in principle three modes: 1. inbound and downscaling : the binary ratio scaler input multiplexer selects data from the dual d1 real time video interface, port a or b and normally writes the result via fifo 3 and dma3 to pci, if dma3 is enabled in master write mode and not used for other purposes. syncs including field id are taken from port a or b (fid defines which base address is used in dma3). 2. outbound and upscaling in direct and line memory mode: the binary ratio scaler takes the data from fifo 3. the dma3 is in master read operation. the scaling result can be selected by the dd1 port output multiplexers. the timing reference signals (vs, hs, llc and fid) are taken from port a or b. 3. outbound and upscaling in field memory mode: the binary ratio scaler takes the data from fifo 3. the dma3 is in master read operation. the scaling result can be selected by the dd1 port output multiplexers. the vertical sync signal is taken from the vs_a or vs_b port as timing reference signal. at the hs_a or hs_b port the saa7146a generates a reset signal for each field. the pxq is an output signal which is connected to the write enable port of the memory. if an interlaced source is selected (different base addresses for odd and even fields), the field detection must be set to free toggle mode, due to the missing horizontal sync signal. table 69 brs control register offset (hex) name bit type description inbound outbound 58 brsdatasel and mode 31 and 30 rw source select for brs video data : 00: video data stream from a 11: read from dma_3/fifo 3 01: video data stream from b 10: reserved brssyncsel 29 rw source select for brs sync signals : 0: take ha, va, fa, llc_a as select in the initial setting of dual d1 interface; see table 66. in direct and line memory mode the same setting as in the inbound mode is select 1: take hb, vb, fb, llc_b as select in the initial setting of dual d1 interface; see table 66. in ?eld memory mode the horizontal sync port must set to output to get the a ?eld reset signal for a ?eld memory byo 28 to 19 rw vertical offset, counted in lines, after selected vertical sync edge until data is captured from dd1 byo de?nes a vertical offset, counted in lines, after selected vertical sync-edge until data is read from the fifo. for ?eld memory mode byo must be 000h. the video window is selected by numlines, numbytes, pitch and base address. brs_v 18 and 17 rw vertical downscaling: vertical upscaling: 00: write every line to dma3 00: regular read 01: write every 2nd line only 01: read every line twice 10: reserved 10: reserved 11: write every 4th line only 11: read every line 4 times
1998 apr 09 88 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 58 bxo 16 to 7 rw horizontal offset, counted in quali?ed llc cycles, after selected horizontal sync edge, till data is captured from dd1 bxo de?nes a horizontal offset, counted in llc cycles, after selected horizontal sync edge till data is read from the fifo in ?eld memory mode the following offsets depending on the horizontal scaling ratio must be selected to guarantee the correct outrun behaviour of the scaler (see table 70). the video window is select by numlines, numbytes, pitch and base address brs_h 6 to 4 rw horizontal downscaling (see section 7.10.1): horizontal upscaling: 000: every pixel is captured 000: provide every sample once 001: every 2nd pixel is captured 001: provide every sample twice 010: reserved 010: reserved 011: every 4th pixel is captured 011: provide every sample 4 times 100: reserved 100: reserved 101: reserved 101: reserved 110: reserved 110: reserved 111: every 8th pixel is captured 111: provide every sample 8 times read mode 3 and 2 rw reserved 00: line memory mode 01: field memory mode 10: direct mode with pixel repetition for not qualified bytes. 11: direct with grey pixel (10h for luminance and 80h for chrominance values) for not qualified bytes. pci format 1 and 0 rw output format pci side: input format pci side: 00: yu v4:2:2 00: yu v4:2:2 01: y8, only luminance 01: reserved 10: y2, 2 msbs of y only 10: reserved 11: y1, 1 msb of y only 11: reserved offset (hex) name bit type description inbound outbound
1998 apr 09 89 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 70 horizontal offset values for the ?eld memory mode 7.12.5 hps programming register table 71 hps control register ratio offset 1 0ch 2 0ch 4 16h 8 2eh offset (hex) name bit type description 5c hpsdatasel 31 and 30 rw source select for hps video data : 00: input video stream for hps is taken from port_a 01 input video stream for hps is taken from port_b 10: y-byte from port_b, c-byte from port_a (cref must provide at port_a) 11: y-byte from port_a, c-byte from port_b (cref must provide at port_b) mirror 29 rw left-right ?ip (mirroring), e.g. for vanity picture: 0: regular processing 1: left-right flip, accessible only if xt (number of pixel after horizontal prescaling) is less than 384 pixels hpssyncsel 28 rw source select for hps sync-signals : 0: take ha, va, fa, llc_a as selected in table 66 1: take hb, vb, fb, llc_b, as selected in table 66 - 27 to 24 rw reserved hyo 23 to 12 rw vertical offset (start line) of hps operation, counted in horizontal source/input events, after selected vertical sync edge - 11 to 0 rw reserved
1998 apr 09 90 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.12.6 v ertical and horizontal scaling table 72 hps, vertical scaling offset (hex) name bit type description 60 yacm 31 rw y (vertical) scaler accumulation (calculation) mode of vertical arithmetic : 0: arithmetic operates as a linear phase interpolation (lpi) 1: arithmetic operates as accumulating fir filter in vertical direction. ysci 30 to 21 rw y scaler increment for vertical downscaling : ysci = int [1024 (n il /n ol - 1) for yacm = 0 ? lpi ysci = int [1024 (1 - n ol /n il )] for yacm = 1 ? accumulation mode n il = number of qualified scaler input lines n ol = number of output lines yacl 20 to 15 rw accumulation sequence length of the y (vertical) processing : defines vertical accumulation sequence length of input lines if accumulation fir filter mode is selected yacm, yacl has to fit to the vertical scaling factor (defined by ysci) ypo 14 to 8 rw vertical start phase for vertical scaling of the odd ?eld : ypo = phol 128 (phol represents a phase offset with values between logic 0 and logic 1, where the logic 1 represents a distance between two consecutive lines of the input pattern) ype 7 to 1 rw vertical start phase for vertical scaling of the even ?eld : ype = phol 128 (phol represents a phase offset with values between logic 0 and logic 1, where the logic 1 represents a distance between two consecutive lines of the input pattern). - 0 rw reserved
1998 apr 09 91 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 73 hps, vertical scale and gain table 74 pre?lter selection for luminance component y offset (hex) name bit type description 64 pfy 31 to 28 rw pre?lter selection for luminance component y : h(z) = h1(z) h2(z) h3(z) h1, h3 = 1 + z - 1 h2=1+a z - 1 +z - 2 see table 74 pfuv 27 to 24 rw pre?lter selection for colour difference signals uv : h(z) = h1(z) h2(z) h3(z) h1=1+z - 1 h2=1+a z - 1 +z - 2 h3=1+z - 2 see table 75 - 23 to 19 - reserved dcgy 18 to 16 rw dc gain control of y scaler : dependent on active coef?cients and the sequence length, the amplitude gain has to be renormalized. gain factor = 2 (dcgy + 1); see table 76. the resulting factor is a function of cyi and dcgy. the resulting weight factor = 0 for cyai = cybi = 0 or cyai = cybi = 1 or dcgy >5 otherwise weight = weighting factor/gain factor; see table 77. cya 15 to 8 rw coef?cient select for y (vertical) processing in accumulation mode. for improvement of vertical ?ltering the accumulated lines can be weighted. weighting factor = 2(2 cybi + cyai - 1); see table 78. cyb 7 to 0 rw pfy1 pfy0 pfy1 pfy0 h1 h2 h3 a x x 0 0 bypass bypass bypass x x x 0 1 active bypass bypass x x x 1 0 active bypass active x 0011 active active active 2 0111 active bypass bypass 15 16 1011 active bypass active 7 8 1111 active active active 3 4
1998 apr 09 92 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 75 pre?lter selection for colour difference signals uv table 76 dc gain control of y scaler table 77 weight factor as a function of cyi and dcgy table 78 coef?cient select for y (vertical) processing in accumulation mode pfy1 pfy0 pfy1 pfy0 h1 h2 h3 a x x 0 0 bypass bypass bypass x x x 0 1 active bypass bypass x x x 1 0 active bypass active x 0011 active active active 2 0111 active bypass bypass 15 16 1011 active bypass active 7 8 1111 active active active 3 4 dcgy2 dcgy1 dcgy0 dcgy gain factor 00002 00114 01028 011316 100432 101564 1106128 1117256 cyi dcgy 01234567 000000000 1 1 2 1 4 1 8 1 16 1 32 1 64 00 21 1 2 1 4 1 8 1 16 1 32 00 301 1 2 1 4 1 8 1 16 00 cybi cyai cyi weighting factor 0000 0111 1022 1134
1998 apr 09 93 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 79 hps, horizontal prescaler table 80 selection of output gain offset (hex) name bit typ. description 68 - 31 and 30 - reserved dcgx 29 to 27 rw dc gain control of x prescaler (see table 57): depending on the number of active coef?cients 2 in the accumulation sequence and the sequence length, the output amplitude gain has to be set to as given in table 80. - 26 to 24 - reserved xpsc 23 to 18 rw prescaling factor of the x prescaler : de?nes accumulation sequence length and subsampling factor of the input data stream: xpsc = trunc (n ip /n op - 1) n op = number of prescaler output pixel n ip = number of qualified scaler input pixel. xacm 17 rw x (horizontal) prescaler accumulation mode of accumulating fir : 0: accumulating operates overlapping 1: non overlapping accumulation (must be set to bypass the prescaler). - 16 - reserved cxy 15 to 8 rw coef?cient select for x prescaler (luminance component y) : for dc gain compensation of prescaler the accumulated pixels can be weighted by 1 or 2. cxyi de?nes a sequence of 8 bits, which control the coef?cients: cxyi = 0: pixel weighted by 1 cxyi = 1: pixel weighted by 2 cxuv 7 to 0 rw coef?cient select for x prescaler (colour difference signals uv) : for dc gain compensation of prescaler the accumulated pixels can be weighted by 1 or 2. cxuvi de?nes a sequence of 8 bits, which control the coef?cients: cxuvi = 0: pixel weighted by 1 cxuvi = 1: pixel weighted by 2 dcgx2 dcgx1 dcgx0 gain 0001 001 1 2 010 1 4 011 1 8 100 1 2 101 1 4 110 1 8 111 1 16
1998 apr 09 94 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 81 hps, horizontal ?ne-scale 7.12.7 bcs table 82 bcs control table 83 luminance brightness control table 84 luminance contrast control offset (hex) name bit typ. description 6c xim 31 rw horizontal interpolation mode : 0: normal mode, sample phase is calculated for every qualified sample 1: fixed phase, sample phase is fixed to the value set by xp xp 30 to 24 rw start phase for horizontal ?ne scaling xp = pho p 128 (phop represents a phase offset with values between 0 and 1, where the 1 represents a distance between two consecutive pixels of the input pattern) xsci 23 to 12 rw x scaler increment for ?ne (phase correct) scaling in horizontal pixel phase arithmetic : xsci = int [(n ip /n op ) 1024/(spsc + 1)] n op = number of output pixels n ip = number of qualified scaler input pixels. hxo 11 to 0 rw horizontal offset (horizontal start) of input source for hps, counted in quali?ed pixels with pxq, after selected horizontal sync edge. offset (hex) name bit type description 70 brig 31 to 24 rw luminance brightness control; see table 83 cont 23 to 16 rw luminance contrast control; see table 84 - 15 to 8 - reserved satn 7 to 0 rw chrominance saturation control; see table 85 d7 d6 d5 d4 d3 d2 d1 d0 gain 11111111255 (bright) 10000000128 (ccir level) 000000000 (dark) d7 d6 d5 d4 d3 d2 d1 d0 gain 01111111 1.999 (max. contrast) 010000001 (ccir level) 000000000 (luminance off)
1998 apr 09 95 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 85 chrominance saturation control 7.12.8 c hroma key table 86 chroma key range d7 d6 d5 d4 d3 d2 d1 d0 gain 01111111 1.999 (max. saturation) 010000001 (ccir level) 000000000 (colour off) offset (hex) name bit type description 74 vl 31 to 24 rw set lower limit v for chroma keying (8-bit; twos complement): 1000 0000: as maximum negative value = - 128 signal level 0000 0000: limit = 0 0111 1111: as maximum positive value = +127 signal level vu 23 to 16 rw set upper limit v for chroma keying (8-bit; twos complement): 1000 0000: as maximum negative value = - 128 signal level 0000 0000: limit = 0 0111 1111: as maximum positive value = +127 signal level ul 15 to 8 rw set lower limit u for chroma keying (8-bit; twos complement): 1000 0000: as maximum negative value = - 128 signal level 0000 0000: limit = 0 0111 1111: as maximum positive value = +127 signal level uu 7 to 0 rw set upper limit u for chroma-keying (8-bit; twos complement): 1000 0000: as maximum negative value = - 128 signal level 0000 0000: limit = 0 0111 1111: as maximum positive value = +127 signal level
1998 apr 09 96 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 87 hps output and formats table 88 output formats offset (hex) name bit type description 78 matrix 31 and 30 rw yuv to rgb conversion, gamma compensation 00: no yuv to rgb conversion 10: yuv to rgb conversion linear 01: reserved 11: yuv to rgb conversion with compensation of gamma-pre-correction - 29 and 28 - reserved outformat 27 to 24 rw output format, depends on matrix programming; see table 88 23 and 22 rw chroma line select for indeo-9 21 and 20 rw chroma pixel select for indeo-9 shift 17 rw 0: normal mode, all bytes stay msb aligned 1: shift mode, shift right of all bytes, fill msb position with logic 0, this mode has meaning only for output formats defined in bytes, undefined result in non-byte modes dither 16 rw dither: applies only to formats with reduced bit resolution, (#) that derived from higher bit resolution formats: 1: dither is applied by linear one-dimensional error diffusion 0: dither algorithm is not applied, just truncation code (hex) output format 0 yuv4:2:2, (16=8 - 8), composed rgb16 ( 5:6: 5), composed, # 1 yuv4:4:4, composed, packed rgb24, composed, packed 2 reserved a rgb32 (8 : 8 : 8 : 8), composed 3 yuv4:1:1, composed a rgb15 (1 : 5 : 5 : 5), composed, # 4 yuv2 rg a b15 (5 : 5 : 1 : 5), composed, # 5 reserved reserved 6 y8, monochrome reserved 7 yuv8 ( 4:2: 2), pseudo clut, # rgb8 ( 3:3: 2), pseudo clut, # 8 yuv4:4:4, de-composed reserved 9 yuv4:2:2, de-composed reserved a yuv4:2:0 (2 2 :1:1) mpeg, de-composed. reserved b yuv9 (4 2 :1:1) indeo-9, de-composed. reserved c reserved reserved d y1 reserved e y2 reserved f yuv1 reserved
1998 apr 09 97 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 89 clip control offset name bit type description 78h - 15 to 10 - reserved clipck 9 and 8 rw clipping by chroma key ck (or msb of a -8): or-ed with other clip list or clip-bit mask, if clipmode is enabled 00: chroma key ck is not used for clipping, ck ?a 01: chroma key ck is not used for clipping, inverted ck ?a 10: clipping, based on chroma key ck bit 11: clipping, based on chroma key ck bit inverted - 7 - reserved clipmode 6 to 4 rw clipping based on dma2 read information : or-ed with chroma key ck, if clipck is enabled 000: no clipping based on dma2 read, dma2 can be used to write decomposed format u 001: no clipping based on dma2 read; dma2 reads 8-bit- a to substitute ck in a -formats 010: reserved 011: reserved 100: clipping, based on pixel clip list, rectangular overlays 101: clipping, based on pixel clip list, rectangular overlays, inverted 110: clipping, based on pixel clip bit mask 1-bit/pixel 111: clipping, based on pixel clip bit mask 1-bit/pixel, inverted recinterl 3 rw select interlaced mode for rectangular overlays : 0: normal mode 1: interlaced mode, this bit must be set if only one clip list for both fields is available. this function assumes that the odd field is always above the even field. - 2 - reserved clipout 1 and 0 rw use of dma3 to report (write) key of clip information back: 00: no clip output, dma3 can be used to write decomposed format v, or to serve brs, read or write 01: dma3 writes chroma key information ck; 1-bit/pixel 10: dma3 writes back (clip mask-ck); 1-bit /pixel 11: dma3 writes applied pixel clipping back; 1-bit/pixel 7.13 scaler event description the rps is controlled by the pause command on special events. this section describes the video events. because of these video events a defined time for an upload is given. table 90 shows the upload handling for the scaler registers. for special applications it can also be useful to select other combinations. for this the termination of the upload must guarantee that the upload is completed before the processing restarts, e.g. with a new line or a new field. to avoid conflicts, e.g. change of vertical settings during vertical processing, the maskwrite command can be used to change single bits within a dword. each video event can force only one upload at a time. this means that the video event is cleared by the circuit as described below, if the corresponding upload has occurred.
1998 apr 09 98 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 90 upload handling for the scaler registers register offset (hex) video event description initial setting of dual d1 interface 50 no video event the initial settings of the dual d1 interface contains all control bits of the scaler part which do not change during a cyclic processing of the video path. these control bits must be initialized at the start of the processing. the different upload conditions of the video path depend on these control bits. changing these bits during the cyclic processing can cause internal pulse signals which generate video events. these events may not ?t into the sequence for the cyclic processing. video data stream handling at port d1_a 54 vbi_a vertical blanking indicator at vs_a port: the vbi is a v-pulse which depends on the selected edge of the vertical blanking interval. the edge is de?ned by the sync_a bits. the selected mode depends on the accepted sync signals. this register can be uploaded with this v-pulse. video data stream handling at port d1_b 54 vbi_b vertical blanking indicator at vs_b port: the vbi is a v-pulse which depends on the selected edge of the vertical blanking interval. the edge is de?ned by the sio_b bits. the selected mode depends on the accepted sync signals. this register can be uploaded with this v-pulse. brs control register 58 brs_done inactive brs data path: in write mode the brs data path is inactive from the falling edge of vgt at the output of the brs which means that target line and target byte are reached to the start of the next ?eld (v-pulse which triggered the brs acquisition). for the read mode this register contains only initial settings which can not change during cyclic processing. hps control 5c hps_done inactive hps data path between two video windows: the hps data path is inactive from the falling edge of the vgt at the output of the hps, indicating that target line and target byte are reached, to the start of the next window processing. v-pulse at the hps acquisition input. hps vertical scale 60 hps vertical scale and gain 64 chroma key range 74 hps output and formats 78 clip control 78 hps, horizontal prescale 68 hps_line_done inactive hps data path between two lines: the hps data path is inactive from the falling edge of the hgt at the output of the hps, indicating that target byte are reached to the start of the next line processing. rising edge of the hgt at the hps acquisition output. hps, horizontal ?ne-scale 6c bcs control 70
1998 apr 09 99 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.14 clipping the saa7146a supports clipping in the hps data path. clipping can be achieved with the chroma key information or with clip data information coming via master read through fifo 2. both sources will be or-ed and can be switched on/off or inverted individually. these settings are controlled by the registers clipck and clipmode. the information read via fifo 2 can be used for clipping with rectangular overlays or for bit mask clipping. the overlay clipping supports up to 16 rectangular overlays using 64 dwords. the bit mask clipping allows an arbitrary number of window clips of any size or shape. this mode needs one bit for every pixel. chroma or clip information can be written to system memory via fifo 3. this is controlled by the clipout register. it is possible to combine the clip information with the inversion of the applied (foreground) chroma key. the result is a mask leaving the (background) area free. this mask can be read back in the next field to clip a different video stream to be placed into the same window as background (blue boxing). it should be noted that planar output formats overrule the use of fifo 2 and fifo 3 for clipping. only chroma clipping is available and no clip information can be written. 7.14.1 b it mask clipping the bit mask clipping will use one dword as clip data for 32 pixels. the first bit of clip data is the msb. 7.14.2 r ectangular overlay clipping the rectangular overlay clipping is responsible for occluding rectangular overlay windows lying over a video window. the rectangular clipping algorithm needs two lists; one for pixels and one for lines. every list element in both lists contains a coordinate and display information for every overlay window. the 64 dword fifo 2 allows up to 16 overlay windows, each having two pixel list entries and two line list entries. the rectangular overlay clipping can be used in interlaced or non-interlaced mode. this is controlled by the recinterl register bit. the overlay window coordinates are defined for the target window, independent of whether the video will be written interlaced or non-interlaced into the target window. every overlay window is defined by its top/left and bottom + 1/right + 1 coordinates. the coordinates are relative to the top left (0, 0) reference of the video window. the overlay clipping combines the coordinates with display information which is a overlay/no_overlay (1, 0) bit for each overlay window. a simple example, shown in fig.28, illustrates the relationship between coordinates and display information. in this example one overlay window a (5, 1; 8, 3) is defined. relevant coordinates for the algorithm are the coordinates where display information changes. at the top/left coordinates (5, 1) the display information will be set to 1 (overlay). therefore, first list entries are (5, 1) for the pixel list and (1, 1) for the line list. the overlay will end at the bottom/right coordinates plus one, e.g. at (9, 4) (8 + 1, 3 + 1). this will lead to the list entries (9, 0) for the pixel list and (4, 0) for the line list. the central element of the rectangular overlay clipping combines the display information of lines and pixels held in the registers pixel_info and line_info. this unit will provide the no_display information when both line and pixel display information are set to no_display. in the example shown in fig.28, this will happen for the pixels 5 to 8 and for the lines 1 to 3. if there is more than one overlay window, the window display information of all windows will be combined into one display information. if any of the display information of any window is indicated no_display the actual pixel will not be displayed. this ensures that overlapping overlay windows will be handled by the hardware, since the video information will only be displayed when no window is lying over it. since the overlapping information is only implicitly in the lists, the overlapping information need not be taken into account during the creation of the lists. the main part of the algorithm is responsible for loading the display information registers pixel_info and line_info. both will be initialized to display. line_info will be updated at the beginning of every line, when the line counter is equal to the line_nr in the line list. pixel_info will be updated when the pixel counter is equal to the pixel_nr in the pixel list. if there is no new information both registers will hold their old values. both line and pixel list have to be sorted from top to bottom or left to right coordinates and are not allowed to have two consecutive list elements with the same coordinate. in the example shown in fig.29, the list entry with line coordinate 1 will hold the display information of window a and the no_display information of window c, so two list elements with the same coordinate are merged into one. the last elements in the lists are characterized by the coordinate 0.
1998 apr 09 100 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.14.2.1 memory organization for rectangle overlay windows. every overlay window is defined by two corners with four coordinates. one dword holds one 11-bit coordinate and 16-bit with the display information for up to 16 overlay windows. table 91 dword organization for rectangular overlay windows unused coordinate display info bit 31 to bit 27 (5-bit) bit 26 to bit 16 (11-bit) bit 15 to bit 0 (16-bit) fig.28 example 1 - rectangular overlay clipping. handbook, full pagewidth mgg267 pixel 0 0 aaaa aaaa aaaa 1 2 3 4 123456789 a 51 0 9 relevant coordinates shaded dark line a 11 0 4 fig.29 example 2 - rectangular overlay clipping. handbook, full pagewidth mgg269 0 0 ccc aaaa aaaa b b b b b b b b b b b b b b b b aaa 1 2 3 4 5 6 7 123456789 relevant coordinates shaded dark pixel a 0 110 100 101 001 011 111 xxx 2 3 5 6 9 0 bc line a 0 110 011 001 101 111 xxx 1 3 4 7 0 bc
1998 apr 09 101 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a the two lists, pixel list and line list, are interlocked in the 64 dword memory. the pixel list is located at the even addresses, the line list at the odd addresses. this organization reduces the number of dwords to be loaded, if there are less then 16 overlay windows. for example, 5 overlay windows need 20 dwords for the coordinates and 2 dwords as eof marker. 7.14.2.2 driver algorithm overlay window coordinates are relative to the video window and can range between 0, 0 and 2047. relevant coordinates are top/left, bottom + 1/right + 1 of the overlay windows. if an overlay window has its bottom/right coordinates at the bottom/right of the video window its relevant coordinates bottom + 1/right + 1 would exceed the coordinate range and therefore do not have to be inserted into the lists. build lists: build sorted lists of lines and pixels containing top/left, bottom + 1/right + 1 coordinates of every overlay window, without having consecutive list entries with the same coordinate. every list will have an end of list entry with all coordinate bits set to zero. this eol entry will follow the last entry. if there are 16 overlay windows and no double coordinates the lists are full and there is no last entry. insert display information: for every relevant coordinate in both lists and for every overlay window, if the coordinate in the line/pixel list is in between the top/bottom or left/right coordinates of the overlay window then set the display information bit to 1 (display). otherwise, set the display information bit to 0 (no_display). 7.15 data expansion bus interface (debi) 7.15.1 g eneral description the debi performs 16-bit parallel i/o in immediate (direct) transfer mode and block transfer mode. the immediate mode is used to transfer a byte, word or dword to or from the target device. the block transfer mode offers the possibility to read or write up to 32 kbytes data blocks. 7.15.2 f eatures 8-bit and 16-bit slaves supported external interrupt supported, dma suspend/resume function byte, word and dword transfers supported slaves with or without handshake ability supported due to programmable cycle time different endian types supported pci dma master transfer in block mode optional address increment in block mode. 7.15.3 debi pins there are 21 debi pins. most of the control signals represent different functions with respect to the selected interface mode (intel/isa or motorola/68 kbytes). table 92 debi pin list pin name type description ad15 to ad0 input/output multiplexed address and data lines as_ale output address strobe/address latch enable uds_wrn output upper data strobe/write not lds_rdn output lower data strobe/read not rwn_sbhe output read/write not/system byte high enable dtack_rdy input data acknowledge/ready (should be pulled high if not used) gpio3 input/output (used here as input only) optional external interrupt input
1998 apr 09 102 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.15.4 f unctional description an immediate access cycle consists of one address phase and one data phase. a block transfer with address increment enabled consists of several consecutive address/data phase couples. a block transfer with disabled address increment consists of one address phase followed by several data phases. the as_ale signal toggles only for a new address phase.the single bytes or words are assembled/disassembled to/from dwords. this includes byte lane swapping since 8-bit devices use for data transfer ad7 to ad0 only, (ad15 to ad8 are used in address phase too, since all 16 ad lines are used for addressing.) fig.30 debi interface. handbook, full pagewidth data mux and cycle control transfer control and data assembling/disassembling debi fifo as_ale lds_rdn uds_wrn dtack_rdy rwn_sbhe gpio3 (xirq) ad16 (15 to 0) multiplexed adress/data lines 16/8-bit slave target bus control signals motorola style intel style debi_config command words debi_ad dma address block length status 32 debi_command mhb062 saa7146a 32 immed. data 32 32 8 8 32
1998 apr 09 103 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.15.4.1 target bus cycle in intel mode the saa7146a starts a target transfer cycle by placing the target address on the multiplexed address/data lines (ad15 to ad0). the address latch enable (ale) is then asserted (set low) indicating that the address lines ad15 to ad0 and the sbhe signal are valid (the active low sbhe indicates data transfer on the high byte lane ad15 to ad8). after asserting ale the ad lines are multiplexed for data transfer. valid data on the ad lines is indicated by assertion of wrn in the write mode (data from saa7146a to target), or by assertion of rdn in the read mode (data from target to saa7146a). in the read mode, it is the responsibility of the target to place data on the ad lines as soon as possible following the assertion of rdn. if the target does not require wait states or handshake for data transfer, rdy should then be tied high and the timeout value should be set to 0. if the target requires wait states, but still does not utilize handshake, then the timeout value can be increased. the width of both wrn and rdn pulses will be increased by 1 pci cycle for each count in the timeout value. if the target is capable of handshake, to indicate when it is ready for data transfer, then the rdy signal can be used. since the saa7146a will not evaluate the rdy signal until timeou t + 1 pci cycles have elapsed, it is recommended that timeout be set to a minimum value (usually 0) for maximum throughput. if the target is slow in responding to the rdn/wrn then timeout can be increase to allow the target time to de-assert rdy (pull to low level) for the current data cycle. once the timeout + 1 number of pci cycles have elapsed (from the assertion of rdn/wrn) the transfer control is in a wait for rdy high state. the data transfer cycle will be ended when a timeout condition at rdy high or a rising edge of rdy after timeout is detected. the cycle is ended by de-asserting ale, sbhe and rdn/wrn. it should be noted that in the intel mode the timer must be enabled (tien = 0). the timeout counter is used as delay sampling rdy value to accommodate target reaction delay in generating a valid rdy signal. timeout is not used as an overall cycle watchdog timer (i.e.: to terminate the cycle if rdy fails to become de-asserted). the current cycle will not end and a new cycle will not start until rdy is asserted (high). fig.31 intel style transfer. handbook, full pagewidth mhb063 address phase t dsw t az t min address address write data read data data phase t ah t as t dhr t dsrd t dsrh t dz t idl t dhw t alh t rdy ad(wr) ad(rd) sbhe ale rdn wrn rdy
1998 apr 09 104 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a fig.32 intel style block transfer without address increment. handbook, full pagewidth mhb064 address phase t dsw t az t min address address write data write data read data read data second data phase first data phase t ah t as t dhr t dsrd t dsrh t dhw t rwi t rdy ad(wr) ad(rd) sbhe ale rdn wrn rdy 7.15.4.2 target bus cycle in motorola mode the target transfer cycle starts with applying the target address onto the multiplexed address/data lines. by setting the address strobe (as) to low it is indicated that the direction signal rwn (read/write not) and the address are valid. the as signal is usable as a address latch enable signal. after asserting as low the address/data lines will change to the data transfer state. the indication of valid data in write mode or the request for data in read mode is done by transition of upper data strobe (uds) and/or lower data strobe (lds) to low. since the selection of the upper and lower bytes for transfer is done via lds/uds there is no need for decoding address line a0. only ad15 to ad1 are needed for transmitting the (word-)address. slaves with handshake ability have to drive dtack low when they have placed valid data onto ad16 in read mode or when they have read their data in write mode. the cycle is ended when a timeout condition at inactive dtack or a positive dtack edge is detected. then as, lds, uds and rwn are reset to high. a new cycle will not start before detection of resetting dtack to high.
1998 apr 09 105 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a fig.33 motorola style transfer. handbook, full pagewidth mhb065 address phase t dsw t az address address write data read data data phase t ah t as t dhw t dhr t dsrd t dsrh t dz t idl ad(wr) ad(rd) rwn as uds lds dtack fig.34 motorola style block transfer without address increment. handbook, full pagewidth mhb066 address phase t dsw t az address address write data write data read data read data second data phase first data phase t ah t as t dhw t dsrd t dsrh t dhr t rwi ad(wr) ad(rd) rwn as uds lds dtack
1998 apr 09 106 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 93 timing parameters (t pci : pci clock cycle time, minimum 30 ns) note 1. only relevant to stretch access cycles in intel mode. t min can be negative, i.e. rdy can be set to low before falling edge of rdn/wrn. symbol parameter conditions min. max. unit t as address set-up time t pci - 15 - ns t ah address hold time t pci - 10 - ns t alh delay between de-asserting of rdn/wrn and ale t pci - 15 - ns t az address 3-state time before start of read command t pci - 10 - ns t dhw write data output hold time - 3 - ns t dhr read data input hold time 0 - ns t dsw write data output set-up time t pci - 15 - ns t dsrh read data input set-up time (relative to handshake edge) - 0.7t pci - ns t dsrd read data input set-up time (dumb target, no handshake) 20 - ns t idl idle time before new transfer starts with as_ale (increment mode) write access 2t pci - 10 - ns read access 3t pci - 10 - ns t rwi idle time between two data access strobes in non-increment mode; this parameter depends on fast mode enable fast mode t pci - 10 - ns normal mode 2t pci - 10 - ns t rdy rdy assertion time (intel mode) 1.5t pci - ns t min delay from negative edge of rdn/wrn to de-assertion of rdy; timeout should be adjusted to timeout = t min +1 note 1 - (timeout - 0.5)t pci ns t dz time until slave driven data lines have to go to 3-state, after read cycle is ?nished - 2.0 t pci ns
1998 apr 09 107 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.15.4.3 transfer con?guration when using dumb targets (unable to handshake) or slow targets (unable to pull dtack_rdy immediately), the cycle length is adjusted by using a programmable cycle timer. at timeout in motorola mode the transfer control gets into a defined state by finishing the cycle when a slave is hanging or not able to handshake. in intel mode the transfer control waits for rdy = 1 after timeout, i.e. the timer reflects the rdy reaction time of the target. in any timeout case the timer overflow interrupt (ti) flag is set. the timer starts at the falling edge of uds_wrn/lds_rdn. for initiating a transfer the target address must be specified (16-bit, pointing to the first byte to transfer), the transfer direction (write_n) and the blocklength that indicates how many bytes have to be transferred. for block transfer a 32-bit dma start address (pci) has to be specified in the debi_ad register. when the blocklength is 1 to 4 bytes the data is immediately transferred to/from the debi_ad register. immediate transfer crossing a dword boundary is not allowed. such illegal transfer trials are reported by the format error bit (fe) in the status register. immediate transfer starts with the least significant byte/word of the debi_ad register. the following figures illustrate the protocol of the debi bus for intel mode transfers. these figures contain no formal timing specification (see table 93 for timing) but rather are intended to help in understanding the operation of the debi interface. the debi bus protocol operates in step with the pci clock, so it is shown for reference at the bottom of these diagrams. at slower pci clock rates, the debi transaction time is proportionally increased. it is not necessary to connect a pci clock to the debi target system, since debi does not expect target read data or target driven handshake signals to be synchronous to pci clock. figure 35 shows the non-incremental mode access in the fastest possible configuration (timeout = 0; fast = 1). the overhead for this type of access is 2 pci clock cycles for address phase plus 2 pci clock cycles for each data phase. in this mode, the blocks are easily identified by the falling edge of ale indicating a new target address can be latched. larger timeout values would lead to wider read/write pulses (pulse width = timeout + 1 [pci clock cycles]). disabling the fast mode would force 2 pci clock cycles idle time between read/write strobes. it is not possible to adjust the address phase timing. it is also assumed in this figure that the rdy signal is not used (tied to high level). use of the rdy signal is allowed in this mode and further explained in the next example. figure 36 shows the incremental mode access. this mode will produce an address phase prior to each data phase, and as such has much lower bandwidth than the non-incremental mode. in the example shown, the rdy signal is also used, although that is not a requirement of this mode. the overhead for this type of access is 2 pci cycles for address phase plus 2 pci cycles for data transfer phase plus 3 pci cycles for write (4 pci cycles for read) idle time between the data phase and the next address phase. in the example shown, since rdy was used with a timeout of 2, the resulting data phase was 4 pci cycles, rather than the minimum of 2. in this example the rdy de-asserts within the same pci clock cycle as rdn/wrn, which means rdy low is strobed by the debi interface 1 pci clock cycle after setting rdn/wrn to low (parameter t min = 1 pci clock cycle). due to this a timeout = t min + 1 = 2 (or greater) is required for flexible access stretching, i.e. synchronizing the rdy and stretching the access until rdy is released to high (see description of t min in the timing parameters; table 93). in difference to the example without rdy usage, increasing the value in timeout will not result in wider read/write strobes, as long as the timeout value does not exceed the rdy low phase by more than 1 pci clock cycle. enabling or disabling the fast mode has no effect in incremental mode. it should be noted that the minimum timing illustrated by these diagrams is not the sustainable data rate by the saa7146a through the debi interface. pci-bus latencies, fifo fullness, target behaviour and other factors will affect the sustained data rate. for illustration purposes table 94 provides indication of peak data rates in various debi configurations.
1998 apr 09 108 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a fig.35 pci clock related protocol scheme for non-increment intel mode, no access stretching via rdy. handbook, full pagewidth mhb067 address address write data read data write data read data ad(wr) ad(rd) sbhe ale clk rdn wrn fig.36 pci clock related protocol scheme for intel incremental mode, access stretching via rdy. handbook, full pagewidth mhb068 address address write data read data ad(wr) ad(rd) sbhe ale clk rdn wrn rdy
1998 apr 09 109 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 94 overview of peak data rates for non-increment (burst) block transfer con?gurations at 33 mhz pci clock note 1. these peak data rates could be reached for transfers with large blocklength settings, in a well performing pci-bus system with low bus load and an appropriate target system without cycle stretching or interrupts. 2. no cycle stretching by rdy/dtack possible. protocol mode timeout value word width fast mode transfer direction target side peak data rate overall peak data rate (1) intel/motorola (2) 0 16 bit enabled r/w 33 mbytes/s 23.0 mbytes/s intel/motorola (2) 0 8 bit enabled r/w 16.5 mbytes/s 13.5 mbytes/s intel/motorola 1 16 bit enabled r/w 22 mbytes/s 17.0 mbytes/s intel/motorola 3 16 bit enabled r/w 13.2 mbytes/s 11.2 mbytes/s intel/motorola (2) 0 16 bit disabled r/w 22 mbytes/s 17.0 mbytes/s intel/motorola 1 16 bit disabled r/w 16.5 mbytes/s 13.5 mbytes/s it is possible to halt an actual block transfer by external interrupt. this is achieved by setting the xirq_en bit in the debi_config register and asserting the gpio3 pin input to low while an block transfer is active. if the xresume bit is set to 0, this will end the current block transfer within the next two dwords. when xresume = 1 the transfer will go to a wait state, but the transfer operation will not end (debi_active still asserted). when gpio3 is de-asserted to high the block transfer will resume. the contents of debi_ad and debi_command registers are steadily updated on actual address and block length values during block transfer. due to this it is possible to abort the transfer, read back actual status, do other transfers and resume later with the saved information. it should be noted that after a dword aligned read block transfer (i.e. if blocklength [1:0] + a16 [1:0] = 4 or a16 [1:0] = 0) the read back value of the debi_ad register points to the consecutive address of the just filled pci memory range. after a dword unaligned transfer the read back debi_ad value points 1 dword further (it should be noted that this also effects the value of the remaining blocklength after interrupt; a16 target address read back is not effected by this). rps is able to react on the gpio3 pin events.the 16 ad lines are set to 3-state while debi is in xirq wait state (xresume enabled). to support target devices of different endian type the swap register has to be configured. fig.37 endian swapping. handbook, full pagewidth 3210 2301 3210 4-byte swap the four bytes in a double word are swapped 2-byte swap the two bytes in a 2-byte word are swapped 0123 mhb069
1998 apr 09 110 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.15.4.4 command word description to configure and initiate a transfer there are 3 pci memory mapped command words. a debi register upload after writing to debi_command starts the transfer process. table 95 debi_config table 96 debi_command table 97 debi_page table 98 debi_ad offset name bit type description 7ch xirq_en 31 rw enable external interrupt on gpio3 xresume 30 rw resume block transfer when xirq was de-asserted - 29 - reserved fast 28 rw enable fast mode (short t rwi time) - 27 and 26 - reserved timeout [3:0] 25 to 22 rw timer set-up value (pci clock cycles) swap 21 and 20 rw endian swap type: 00: straight - dont swap 01: 2-byte swap 10: 4-byte swap 11: reserved slave16 19 rw indicates that slave is able to serve 16-bit cycles increment 18 rw enables address increment for block transfer intel 17 rw intel style bus handshake if high, else motorola style tien 16 rw timer enable (active low) - 15 to 0 - reserved offset name bit type description 80h blocklength [14:0] 31 to 17 rw blocklength > 4: block transfer length in bytes 4 3 blocklength > 0: immediate transfer 1 to 4 bytes blocklength = 0: reserved write_n 16 rw transfer direction (write if low) a16_in 15 to 0 rw slave target start address offset name bit type description 84h debi_page 31 to 12 rw debi page table address (not used if page_en = 0) page_en 11 rw enable address paging - 10 to 0 - reserved offset name bit type description 88h debi_ad 31 to 0 rw data input/output in immediate mode or dma start address for block transfer (dword aligned, debi_ad [1:0] have to be set to logic 0)
1998 apr 09 111 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.16 audio interface 7.16.1 g eneral description the saa7146a has two independent audio interface circuits (a1 and a2) for serial input and output of digital audio data streams. the audio interface circuits are based on the i 2 s-bus standard but can be configured to several data and timing formats (with respect to framing, bit clock and synchronisation). lsb first (sony) formats are not supported. up to 5 audio devices with separate serial data lines and dedicated word select lines can be connected directly. the interface also supports devices that share one serial data line for multiple devices to transmit data in different time slots. a time slot consists of one (serial) byte. each interface circuit supports up to 5 serial data lines and related framing signals. a1 and a2 have the same internal structure. they share the audio interface pins, i.e. the pins can be accessed and utilized by one or the other audio interface circuits at a time. in order to support systems with asynchronous or mixed audio sampling rates (e.g. 48 and 44.1 khz raster, or 48 khz 2 16-bit stereo and 8 khz 8-bit mono), the two audio interface circuits can run independently and even asynchronously regarding bit clock rate, sampling rate and framing (word select) signals. the two circuits can also be combined into one synchronous interface sharing bit clock and framing and sampling frequencies. each audio interface has two fifos (one for input and one for output), and two associated dma control circuits (one for master read and one for master write), to exchange data with any pci address, e.g. main memory. the data structure and signal flow control is time slot oriented and also supports local feedback from input to output and from one timeslot to another time slot. a set of time slots can be looped into one audio super frame containing up to 256 bits (32 time slots). the signal flow is defined per time slot and programmed by a time slot list. 7.16.2 b asics of i 2 s- bus specification the i 2 s-bus transports digital audio (sound) signals serially between ics and consists of three signals: a continuous bit clock bclk (or sck) with (n 8) multiple of the audio sample frequency a serial data wire sd, transporting the data in serial bursts with msb first a framing signal ws (word select) defining (synchronizing) the start of a serial data burst. ws and bclk signals are provided by the master device. the saa7146a audio interfaces can be configured as master or slave. a data receiver must latch the data on sd line with the rising edge of the bit clock bclk. to satisfy the requirements regarding set-up and hold times more easily (and secure) it is recommended that the transmitter sends its data on the falling edge. set-up and hold times are specified parameterized; i.e. as a percentage of the actual bit clock. the serial data starts one clock cycle after an edge of ws or synchronous to the edge. the word (burst) length of transmitter and receiver may be different. missing lsbs are filled with zeros, excess lsbs are truncated. there are other formats for transmitting serial digital audio data between ics which are slightly different but still very similar to the i 2 s. the data set-up and hold times or even the definition of an active clock edge may vary. the word select or framing signal can be in sync with the msb of the data burst instead of one clock cycle ahead. the sony format is quite different, as it starts with lsb first. fig.38 general application schematic of the audio interface. handbook, full pagewidth mgg275 master ws bclk sd in/out aclk (reference clock) slave
1998 apr 09 112 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.16.3 a udio interface pins there are 14 audio interface pins. sd1 is output only for a1 and input only for a2, sd4 is output only for a2 and input only for a1. the other pins can be used by either one of the two interface circuits but only one at a time. table 99 audio pin list 7.16.4 a udio interface circuit each of the two audio interface circuits of the saa7146a consists of the following major functional parts: output dword (format) buffer (to load from fifo) output data selector (byte mux 8 to 1) parallel-to-serial converter output pin selector (destination mux) serial data input selector (bit mux 4 to 1) serial-to-parallel converter (1 byte) input dword (format) buffer (to store into fifo) audio input fifo and master write dma feedback (hand) buffer master read dma and audio output fifo bit clock selector or generator time slot counter and word select signal generator. pin i/o function aclk i audio reference clock; multiple of serial bit clock, multiple of audio sampling; maximum frequency 25 mhz; has to be provided even in slave mode bclk1 i/o bit clock 1 bclk2 i/o bit clock 2 sd0 i/o serial data output for audio interface a1 or input for a2 sd1 i/o serial data i/o for audio interface a1 or a2 sd2 i/o serial data i/o for audio interface a1 or a2 sd3 i/o serial data i/o for audio interface a1 or a2 sd4 i/o serial data input for audio interface a1 or output for a2 ws0 i/o word select line 0, as input it is used as super frame sync (trigger) ws1 o word select output line 1 ws2 o word select output line 2 ws3 o word select output line 3 ws4 i/o word select line 4, as input it is used as super frame sync (trigger)
1998 apr 09 113 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.16.4.1 audio clock selection the clock divider circuit offers 16 different clock stages. to transform a reference clock of 24.576 mhz to a bit clock for an 8 khz and 8-bit sampling (just 8-bit serial), a clock division of 384 has to be selected. to transform a reference clock of 24.576 mhz to a bit clock for a 48 khz sampling and 64-bit framing, a division of 8 has to be selected. the bit clock is divided by 8, which defines a time slot corresponding to the time span of one byte in serial protocol. the time slot counter gets a count pulse every time slot. it can be running free or can be triggered (reset) via an external word select signal (super frame sync). audio interface circuit a1 can be triggered by ws0, audio interface circuit a2 can be triggered by ws4. a time slot list processor generates word select output signals and the internal signals to control the signal flow per time slot. a time slot list contains up to 16 records, each 32 bits wide, supporting super frames with up to 32 time slots. ws0 (or ws4) triggers the time slot generator and time slot counter directly in sync or are one clock cycle ahead. the ws signals can be generated in sync with the time slot (i.e. msb of serial data) or 1-bit clock cycle ahead. each of the two audio interface circuits a1 and a2 has its own independent timing generator. extra control bits define which of the two timing generators drive which of the word select pins ws0 to ws4. fig.39 audio clock control. handbook, full pagewidth clk source select a1 aclk divider 1 aclk bclk1 bclk2 time slot counter 1 tsl1 a1 tsl2 a2 a1 bclk1 a2 bclk2 1/8 bclk1_oen bclk2_oen clk source select a2 aclk divider 2 aclk time slot counter 2 1/8 ws0 ws4 eos1 eos2 mgg281
1998 apr 09 114 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.16.4.2 audio data path figure 40 illustrates the audio data path. an input multiplexer selects serial data from one of four sd pins. a1 can select sd0 and the common serial data pins sd1, sd2 and sd3. a2 can select sd4 and the common serial data pins sd1, sd2 and sd3. a serial-to-parallel converter collects 8 bits to form a byte in a timeslot. at the end of the time slot this byte can be stored into a dword buffer, and/or into the feedback buffer or can be thrown away. the first byte that is latched, is placed into the first byte place of the buffer, the second byte that is latched, is placed into the second byte place, etc. big-endian and little-endian stuffing is supported. if bytes are not latched into a certain buffer, the place pointer of the corresponding buffer is not incremented. the write (fill) pointer of the feedback buffer is reset to its initial position with every start/restart of the super frame. up to four bytes of the input data stream can be placed in the intermediate feedback buffer. they can be selected from the buffer to provide data to the output. the feedback buffer is also read and write accessible via the pci-bus. this allows reading of status information and writing of control information at specific positions in the audio frame. the write access is only possible when the interface is inactive. the samples of the various real world audio signal streams are byte or word interleaved in system memory and pci address space. it is the responsibility of system/board designer and of software/programmer to produce a reasonable sample ordering, e.g. have a 16-bit sample on a word boundary and not crossing a dword boundary. fig.40 audio data flow control in a1 and a2. handbook, full pagewidth mgg277 sd0 sd4 sd3 sd2 sd1 serial data lines feedback buffer status/control information via pci serial-to- parallel parallel- to-serial input buffer 8 8 output buffer audio output fifo 24 dwords audio input fifo 24 dwords 32
1998 apr 09 115 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 100 feedback buffers under control of the time slot list, a collected dword is then stored into the input fifo. the fifo size is determined to 24 dwords. an audio sampling frequency of f s = 48 khz and n = 16 time slots in a super frame results in a maximum data load for the pci from an audio capture dma channel of 768 kbytes/s (the bit clock rate is 6144 kbit/s). that accounts for approximately 13 dwords per regular video line time. to generate audio output signals, a master read dma control fills the output fifo. a dword buffer is loaded from fifo under control of the time slot list. the parallel-to-serial converter takes a byte as programmed in the time slot list from one of the 8 buffer places; 4 in the dword buffer and 4 in the feedback buffer. the serial output is directed to one of the accessible sd pins. positive and negative clock edge data transmission is supported by optional bclk inversion. each record in the time slot list describes, how the bytes appearing on the port, are mapped to the dword wide dma channels, respectively to the feedback or input buffers. a time slot list record consists of 4 bytes. as up to 32 time slots are supported, the time slot list is comprised of 16 dwords of programming for each audio interface circuit a1 or a2 which can be linked together. offset name bit type description 144h fb_buffer1 31 to 0 rw feeds back audio data or stores status/control informations 148h fb_buffer2 31 to 0 rw feeds back audio data or stores status/control informations fig.41 audio data path components. handbook, full pagewidth mgg282 ws4 ws3 ws2 ws1 ws0 43210 43210 sd4 ws sd ws sd sd3 sd2 sd1 sd0 fifo1 fifo1 in out fifo2 tsl2 a2 tsl1 a1 fifo2 in out i/o control dataflow control a1 43210 43210 dataflow control a2
1998 apr 09 116 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a each interface, a1 and a2, uses its own time slot list (tsl) when working independently of each other. the shaded areas are valid for combined processing of tsl1 and tsl2 only. in these modes, tsl1 or tsl2 are used interleaved or concatenated, to achieve one single tsl with up to 32 records. both parts of the list control both interface circuits in parallel. all four dma channels are available. the tsls are write only. table 101 time slot list structure record structure tsl1 16 dwords (offset: 180 to 1bch) tsl2 16 dwords (offset: 1c0 to 1fch) bit# name 0 1 2 3 4 5 6 7 8 9 a b c d e f 0 1 2 3 4 5 6 7 8 9 a b c d e f 31 ws0 30 ws1 29 ws2 28 ws3 27 ws4 26 reserved 25 dis_a1 [1] 24 dis_a1 [0] 23 sdw_a1 22 sib_a1 21 sf_a1 20 lf_a1 19 bsel_a1 [2] 18 bsel_a1 [1] 17 bsel_a1 [0] 16 dod_a1 [1] 15 dod_a1 [0] 14 low_a1 13 reserved 12 dis_a2 [1] 11 dis_a2 [0] 10 sdw_a2 9 sib_a2 8 sf_a2 7 lf_a2 6 bsel_a2 [2] 5 bsel_a2 [1] 4 bsel_a2 [0] 3 dod_a2 [1] 2 dod_a2 [0] 1 low_a2 0 eos
1998 apr 09 117 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 102 time slot list bit functions name function ws0 de?ning pattern of word select signal output at ws0 pin; if ws0 pin is input and trigger, ws0 bit is meaningless ws1 de?ning pattern of word select signal output at ws1 pin ws2 de?ning pattern of word select signal output at ws2 pin ws3 de?ning pattern of word select signal output at ws3 pin ws4 de?ning pattern of word select signal output at ws4 pin: if ws4 pin is input and trigger, ws4 bit is meaningless dis_ax [1:0] select serial data input from: 00 : sd0 (for a2); sd4 (for a1) 01 : sd1 10 : sd2 11 : sd3 sdw_ax 0: do not load this byte into the dword buffer 1: load this byte into the dword buffer, place into the next available position sib_ax 0: do not load this byte into the intermediate feedback buffer 1: load this byte into the intermediate feedback buffer, place into the next available position sf_ax 0: do nothing 1: store dword buffer into input fifo, at the next available position lf_ax 0: do nothing 1: load next dword from output fifo into output dword buffer bsel_ax [2:0] select byte for parallel-to-serial converter from output dword buffer or from intermediate feedback buffer: 000: take byte 0 from output dword buffer 001: take byte 1 from output dword buffer 010: take byte 2 from output dword buffer 011: take byte 3 from output dword buffer 100: take byte 0 from intermediate feedback buffer 101: take byte 1 from intermediate feedback buffer 110: take byte 2 from intermediate feedback buffer 111: take byte 3 from intermediate feedback buffer dod_ax [1:0] de?ne on which sd pin the serial output data will appear: if both circuits attempt to drive the same sd pin in the same time slot, a1 gets preference. when a sd pin is not driven actively it is 3-stated. 00: at sd0 (for a1); at sd4 (for a2) 01: at sd1 10: at sd2 11: at sd3 low_ax drive the sd pin which was driven in the previous time slot as output: for 7-bit clock cycles to active low and let then go to 3-state. eos end of superframe: last record in time slot list, next time slot uses ?rst record of the tsl (reset tsl pointer).
1998 apr 09 118 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.16.5 a udio configuration the configuration parameters are selected using two configuration registers, acon1 and acon2. the acon1 register is locally buffered. the download from the shadow register into the working register is performed when a dma protection address is reached or immediately when both interfaces are not active (switched off, initial state). table 103 audio con?guration register 1 (acon1) table 104 audio con?guration register 2 (acon2) offset (hex) name bit type description f4 audio_mode [2:0] 31 to 29 rw de?nes interface activation and combination maxlevel [6:0] 28 to 22 rw de?nes the maximum allowed absolute value for the most signi?cant byte of an audio sample a1_swap 21 rw de?nes if input (captured) data is stuffed in little-endian or big-endian format for a1 (4 byte swap if set) a2_swap 20 rw de?nes if input (captured) data is stuffed in little-endian or big-endian format for a2 (4 byte swap if set) ws0_ctrl [1:0] 19 and 18 rw function control for ws0 line ws0_sync [1:0] 17 and 16 rw pulse position and width control for ws0 line ws1_ctrl [1:0] 15 and 14 rw function control for ws1 line ws1_sync [1:0] 13 and 12 rw pulse position and width control for ws1 line ws2_ctrl [1:0] 11 and 10 rw function control for ws2 line ws2_sync [1:0] 9 and 8 rw pulse position and width control for ws2 line ws3_ctrl [1:0] 7 and 6 rw function control for ws3 line ws3_sync [1:0] 5 and 4 rw pulse position and width control for ws3 line ws4_ctrl [1:0] 3 and 2 rw function control for ws4 line ws4_sync [1:0] 1 and 0 rw pulse position and width control for ws4 line offset (hex) name bit type description f8 a1_clksrc [4:0] 31 to 27 rw de?nes the bit clock source for a1 a2_clksrc [4:0] 26 to 22 rw de?nes the bit clock source for a2 invert_bclk1 21 rw input or output bclk1 with inverted polarity invert_bclk2 20 rw input or output bclk2 with inverted polarity bclk1_oen 19 rw output enable bclk1 (active low) bclk2_oen 18 rw output enable bclk2 (active low)
1998 apr 09 119 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.16.5.1 audio mode control there are 3 audio mode bits to select which tsl is active and how to synchronize and combine them. the first half of table 105 supports asynchronous operation of a1 and a2, each following their own configuration bits and working independent of each other. in the second half of the table, the two interfaces work synchronously, according to the clock configuration setting of a1_clksrc. some special cases are discussed below. audio_mode [2:0] = 7: the two tsls are chained to each other thus enabling a longer tsl, with up to 32 time slots to be built (singer format). there is only one common tsl pointer active which is able to reach the whole address range. the pointer synchronisation is done according to the a1 configuration. there is only one eos bit needed. audio_mode [2:0] = 5 ? 6: both interfaces working synchronously on the same tsl half and with the same record. synchronous change from one tsl to the other tsl when reaching the protection address. by that the tsl can be changed, by switching to the other tsl, without disturbing real time flow of audio streams. there is no time gap necessary for reprogramming a tsl. reprogramming is performed by using the other tsl as shadow. the two tsl pointers are locked, i.e. each one pointing to its own list area, but resetting and incrementing synchronously. table 105 audio_mode control audio_mode [2:0] audio interface a1 audio interface a2 0 off off 1 processing tsl1; synchronisation according to a1 con?guration off 2 off processing tsl2; synchronisation according to a2 con?guration 3 processing tsl1; synchronisation according to a1 con?guration processing tsl2; synchronisation according to a2 con?guration 4 processing tsl1; synchronisation according to a1 con?guration processing tsl2; tsl2 pointer is in sync (locked) to tsl1 pointer; tsl2 pointer = tsl1 pointer + 16 5 processing tsl1; synchronisation according to a1 con?guration processing tsl1 in common with a1; tsl2 pointer = tsl1 pointer 6 processing tsl2 in common with a2; tsl1 pointer = tsl2 pointer processing tsl2; synchronisation according to a1 con?guration 7 processing tsl1 and tsl2 in common with a2, synchronization according to a1 con?guration; tsl1 pointer range is up to 32 records processing tsl1 and tsl2 in common with a1; tsl2 pointer = tsl1 pointer
1998 apr 09 120 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.16.5.2 audio input level monitoring the audio input level monitoring feature allows the control of audio input levels without additional external hardware, by comparing the absolute value of the most significant byte of an audio sample to a programmable reference maximum level. the maxlevel is defined by 7 bits, since serial audio data is transmitted in twos complement and the sign of the compared byte is not relevant for audio level control. therefore, maxlevel is programmable from 0 to 127. the twos complement value ?- 128 ? is not reachable, but also not functionally needed. the comparison results are stored in the 32-bit level report register with one bit per time slot of tsl1 and tsl2, reporting whether there was a level violation in that time slot. the comparison runs all the time and the level report register is reset when it is read by software. table 106 level report register 7.16.5.3 ws line controlling the wsx_ctrl bits define which of the ws lines is output and controlled by which audio interface circuit (a1 or a2). wsx_sync defines the timing of ws signals. table 107 static function control for word select lines table 108 pulse width and position control offset (hex) name bit type description 140 level_report 31 to 0 r stores the violation of maxlevel for all 32 tsl records; reset to 0000h when read. wsx_ctrl [1:0] ws0 function ws1 function ws2 function ws3 function ws4 function 00 3-state, input, rising edge resets tsl1 pointer 3-state 3-state 3-state 3-state, input, rising edge resets tsl2 pointer 01 output, controlled by tsl1 output, controlled by tsl1 output, controlled by tsl1 output, controlled by tsl1 output, controlled by tsl1 10 output, controlled by tsl2 output, controlled by tsl2 output, controlled by tsl2 output, controlled by tsl2 output, controlled by tsl2 11 output, active low output, active low output, active low output, active low output, active low wsx_sync [1:0] pulse function 00 i 2 s style: ws goes active one bit clock cycle before msb of time slot and stays active until lsb, i.e. one bit clock before msb of next time slot 01 ws goes active in sync with msb and stays active until next msb, i.e. active in sync with current time slot 10 ws goes active one bit clock before msb and stays active for one bit clock cycle, i.e. negative edge is in sync with beginning of time slot 11 singer style: ws goes active in sync with msb and stays active for one bit clock cycle and for two bit clock cycles in ?rst time slot of the superframe
1998 apr 09 121 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.16.5.4 bit clock control specific to each audio interface, a1 or a2, is the programming of bit clock source. table 109 clk source de?nition 7.16.6 s witching audio streams there are different levels of switching data streams on and off: dma transfer enable; switching a dma channel audio_mode; switching the two audio interfaces wsx_ctrl; switching a physical channel. the audio_mode and wsx_ctrl programming is locally buffered and gets loaded when the corresponding dma protection address is reached. when both interfaces are off, changes are loaded immediately. if an audio interface is switched on, it will start working at tsl pointer reset. disabling a dma channel clears the corresponding fifo and sets the dma pointers to their base address: this is the initial state. it is recommended to enable the output dma channels before activating the interface, since the output fifo has to be filled with valid output data. it is the responsibility of the software to configure data structures, tsl sequences and protection address in such a way, that they match each other. ax_clksrc [4:0] (hex) a1 bit clock a2 bit clock 1f to 13 reserved reserved 12 aclk divided-by-384 aclk divided-by-384 11 aclk divided-by-256 aclk divided-by-256 10 aclk divided-by-192 aclk divided-by-192 0f aclk divided-by-128 aclk divided-by-128 0e aclk divided-by-96 aclk divided-by-96 0d aclk divided-by-64 aclk divided-by-64 0c aclk divided-by-48 aclk divided-by-48 0b aclk divided-by-32 aclk divided-by-32 0a aclk divided-by-24 aclk divided-by-24 09 aclk divided-by-16 aclk divided-by-16 08 aclk divided-by-12 aclk divided-by-12 07 aclk divided-by-8 aclk divided-by-8 06 aclk divided-by-6 aclk divided-by-6 05 aclk divided-by-4 aclk divided-by-4 04 aclk divided-by-3 aclk divided-by-3 03 aclk divided-by-2 aclk divided-by-2 02 aclk aclk 01 bclk2 bclk1 00 bclk1 bclk2
1998 apr 09 122 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.17 i 2 c-bus interface 7.17.1 g eneral description the i 2 c-bus is a simple 2-wire bus for efficient inter-ic data exchange. only two bus lines are required: a serial clock line (scl) and a serial data line (sda). its a true multi-master bus including collision detection and arbitration to prevent data corruption if two or more masters simultaneously initiate data transfers. serial clock synchronization allows devices with different bit rates to communicate via the same serial bus. the block diagram is shown in fig.42. 7.17.2 f unctional description the i 2 c-bus performs byte oriented data transfers. clock generation and bus control arbitration are controlled by hardware. the status register (iicsta) reflects the status of the interface and the i 2 c-bus (see table 110). an interrupt after execution may be enabled optionally. the bus clock generator supports clock rates from 5 to 400 khz. the i 2 c-bus interface is programmed through the transfer control register (iictrf) which is shown in table 112. a write to this register starts the transfer sequence where up to 3 bytes are transferred: byte2, byte1 and byte0. any of these 3 bytes may be disabled or enabled for use (as data byte or 7-bit address plus rw bit) in three i 2 c-bus protocol functions: start: start/restart and address device cont: transfer data and continue stop: transfer data and stop. all bus operations are done via these three functions. the functional usage of each single byte is defined by the byte specific attribute information (see table 113). fig.42 block diagram of i 2 c-bus serial interface. handbook, full pagewidth mgg278 byte 0 byte 1 byte 2 transfer attributes status register (iicsta) 8-bit shift register bus clock generator control arbitration and sync logic sda scl
1998 apr 09 123 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 110 status register (iicsta); note 1 note 1. the error bits have to be cleared, before a new command can be executed. this may be needed twice after using abort. table 111 selection of i 2 c-bus bit rate; note 1 notes 1. since the maximum width of spikes suppressed by the input filter depends on the pci clock frequency, the appropriate timing parameter of 50 ns from the i 2 c-bus specification is not fulfilled. refer to the document for further details. this document may be ordered using the code 9398 393 40011. 2. the selected bit rate is the maximum bit rate and could be stretched (slowed down) by slaves. offset (hex) name bit type description 90 iiccc [2:0] 10 to 8 rw clock bit rate selection; see table 111 abort 7 rw abort operation: clears busy bit sperr 6 rw bus error due to invalid start/stop condition aperr 5 rw nack: error in address phase dterr 4 rw nack: error in data transmission drerr 3 rw nack: error when receiving data al 2 rw arbitration lost err 1 r general error ?ag: has to be reset by clearing all error ?ags busy 0 r operation ongoing iiccc2 iiccc1 iiccc0 bit rate (2) 1 0 1 pci clock/6400 0 0 1 pci clock/3200 1 0 0 pci clock/480 1 1 0 pci clock/320 1 1 1 pci clock/240 0 0 0 pci clock/120 0 1 0 pci clock/80 0 1 1 pci clock/60
1998 apr 09 124 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 112 transfer control register (iictrf) table 113 attrx1 and attrx0; attribute information for bytex note 1. the generation of na or a is performed by the controller hardware and is not user accessible. 7.17.2.1 abbreviations used in table 113 s: i 2 c-bus start command da: 7-bit device address (bytex7 to bytex1) r/w: read/write# bit (bytex0) d: receive/transmit data (bytex) a: acknowledge na: negative acknowledge (also used for identification of last master read data byte) p: i 2 c-bus stop command. offset (hex) name bit type description 8c byte2 31 to 24 rw data/address register 2 byte1 23 to 16 rw data/address register 1 byte0 15 to 8 rw data/address register 0 attr2 [1:0] 7 and 6 rw attribute information for byte2 attr1 [1:0] 5 and 4 rw attribute information for byte1 attr0 [1:0] 3 and 2 rw attribute information for byte0 err 1 rw general error ?ag: has to be reset by clearing iicsta busy 0 rw operation ongoing attrx1 attrx0 symbol protocol function 1 1 start start and address device, use bytex [7:1] as da7 to d1 and bytex [0] as r/w bit s da7 to da1 r/w a (1) 1 0 cont transfer d and continue, use bytex [7:0] as d7 to d0 d7 to d0 a (1) 0 1 stop transfer d and stop, use bytex as d7 to d0 d7 to d0 a/na (1) p 0 0 nop no operation, dont use this byte
1998 apr 09 125 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.17.2.2 example the protocol sequence for reading three bytes with subaddress access is illustrated in fig.43. the procedure for this read operation is detailed below: 1. address slave, write to iictfr (see fig.44): byte2 [7:1] = da, byte2 [0] = 0 (write), attr2 = start byte1 = subaddress, attr1 = cont byte0 [7:1] = da, byte0 [0] = 1(read), attr0 = start 2. wait until busy = 0 3. check err bit, if it is inactive the slave target is successfully addressed 4. transfer data, write attribute information to iictfr (see fig.45): byte2 = first received data byte, attr2 = cont byte1 = second received data byte, attr1 = cont byte0 = third received data byte, attr0 = stop 5. wait until busy = 0 6. check err bit, if it is inactive iictfr contains valid data. instead of checking the general error flag (err) after each single 3-byte sequence, it is possible to check the err at the end of the whole protocol sequence. during a bus cycle, the busy bit is set high. at the end of a bus cycle an interrupt request is generated if enabled and busy is cleared if no error occurs. writing to the iictrf should not be done while the busy bit is active, otherwise the err flag will be set high. if no transfer errors occur during the three transfer actions, the err bit will be set low. if an error occurs the err bit will be set high and the busy bit stays high. in this case the error and busy flags have to be cleared before starting a new operation. fig.43 protocol sequence for reading three bytes with subaddress access. handbook, full pagewidth s w a a da sa address device and transmit subaddress s r a a da d restart for reading from slave receive data p mgd696 a na d d restart last byte and stop receive data
1998 apr 09 126 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a fig.44 address slave and write to iictfr. handbook, halfpage w da a sa a a s s mgd699 r da fig.45 transfer data and write attribute information to iictfr. handbook, halfpage a d a d p mgd698 na d
1998 apr 09 127 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 7.18 saa7146a register tables table 114 registers and offsets sorted by functional groups offset (hex) name type ram read value after reset corresponding upload bit 00 baseodd1 rw yes unde?ned video dma1 upload 04 baseeven1 rw yes unde?ned 08 protaddr1 rw yes unde?ned 0c pitch1 rw yes unde?ned 10 basepage1 rw yes unde?ned 14 num_line_byte1 rw yes unde?ned 18 baseodd2 rw yes unde?ned video dma2 upload 1c baseeven2 rw yes unde?ned 20 protaddr2 rw yes unde?ned 24 pitch2 rw yes unde?ned 28 basepage2 rw yes unde?ned 2c num_line_byte2 rw yes unde?ned 30 baseodd3 rw yes unde?ned video dma3 upload 34 baseeven3 rw yes unde?ned 38 protaddr3 rw yes unde?ned 3c pitch3 rw yes unde?ned 40 basepage3 rw yes unde?ned 44 num_line_byte3 rw yes unde?ned 94 basea1_in rw read unde?ned immediate write access 98 prota1_in rw read unde?ned 9c pagea1_in rw read unde?ned a0 basea1_out rw read unde?ned a4 prota1_out rw read unde?ned a8 pagea1_out rw read unde?ned ac basea2_in rw read unde?ned b0 prota2_in rw read unde?ned b4 pagea2_in rw read unde?ned b8 basea2_out rw read unde?ned bc prota2_out rw read unde?ned c0 pagea2_out rw read unde?ned 48 pci_bt_v rw yes unde?ned video dma1, 2 or 3 upload 4c pci_bt_a rw read unde?ned immediate write access 120 pci_vdp1 r no 00000000 124 pci_vdp2 r no 00000000 128 pci_vdp3 r no 00000000 12c pci_adp1 r no 00000000 130 pci_adp2 r no 00000000
1998 apr 09 128 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 134 pci_adp3 r no 00000000 - 138 pci_adp4 r no 00000000 13c pci_ddp r no 00000000 fc mc1 rw no 00000100 immediate access 100 mc2 rw no 0000077f 104 rps_addr0 rw no 00000000 108 rps_addr1 rw no 00000000 c4 rps_page0 rw read unde?ned immediate write access c8 rps_page1 rw read unde?ned cc rps_thresh0 rw read unde?ned d0 rps_thresh1 rw read unde?ned d4 rps_tov0 rw read unde?ned d8 rps_tov1 rw read unde?ned 110 psr r no unde?ned - 114 ssr r no unde?ned dc ier rw read unde?ned immediate write access 10c isr rw no 00000000 immediate access e0 gpio_ctrl rw read unde?ned immediate write access 118 ec1r r no 00000000 - 11c ec2r r no 00000000 e4 ec1ssr rw read unde?ned immediate write access e8 ec2ssr rw read unde?ned ec ect1r rw read unde?ned f0 ect2r rw read unde?ned 50 initial settings dd1 port rw yes unde?ned d1 interface upload 54 video data stream handling at port dd1 rw yes unde?ned 58 brs control register rw yes unde?ned brs upload 5c hps control rw yes unde?ned hps section 1 upload 60 hps vertical scale rw yes unde?ned hps section 2 upload 64 hps vertical scale and gain rw yes unde?ned 68 hps horizontal prescale rw yes unde?ned hps section 1 upload 6c hps horizontal ?ne-scale rw yes unde?ned 70 bcs control rw yes unde?ned hps section 2 upload 74 chroma key range rw yes unde?ned 78 hps output and formats clip control rw yes unde?ned 8c iictfr rw yes unde?ned i 2 c-bus upload 90 iic_sta rw yes 000004xx offset (hex) name type ram read value after reset corresponding upload bit
1998 apr 09 129 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 115 registers and offsets sorted by address-offset 88 debi_ad rw yes unde?ned debi upload 7c debi_config rw yes unde?ned 80 debi_command rw yes unde?ned 84 debi_page rw yes unde?ned f4 acon1 rw read unde?ned immediate write access f8 acon2 rw read unde?ned 144 fb_buffer1 rw no 00000000 immediate access 148 fb_buffer2 rw no 00000000 140 level_rep r no 00000000 - 180-1bc audio time slot registers 1 w no no read back immediate access 1c0-1fc audio time slot registers 2 w no no read back offset (hex) name type ram read value after reset corresponding upload bit 00 baseodd1 rw yes unde?ned video dma1 upload 04 baseeven1 rw yes unde?ned 08 protaddr1 rw yes unde?ned 0c pitch1 rw yes unde?ned 10 basepage1 rw yes unde?ned 14 num_line_byte1 rw yes unde?ned 18 baseodd2 rw yes unde?ned video dma2 upload 1c baseeven2 rw yes unde?ned 20 protaddr2 rw yes unde?ned 24 pitch2 rw yes unde?ned 28 basepage2 rw yes unde?ned 2c num_line_byte2 rw yes unde?ned 30 baseodd3 rw yes unde?ned video dma3 upload 34 baseeven3 rw yes unde?ned 38 protaddr3 rw yes unde?ned 3c pitch3 rw yes unde?ned 40 basepage3 rw yes unde?ned 44 num_line_byte3 rw yes unde?ned 48 pci_bt_v rw yes unde?ned video dma 1 2 or 3 upload 4c pci_bt_a rw read unde?ned immediate write access 50 initial settings dd1 port rw yes unde?ned d1 interface upload 54 video data stream handling at port dd1 rw yes unde?ned 58 brs control register rw yes unde?ned brs upload 5c hps control rw yes unde?ned hps section 1 upload offset (hex) name type ram read value after reset corresponding upload bit
1998 apr 09 130 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 60 hps, vertical scale rw yes unde?ned hps section 2 upload 64 hps, vertical scale and gain rw yes unde?ned 68 hps horizontal prescale rw yes unde?ned hps section 1 upload 6c hps horizontal ?ne-scale rw yes unde?ned 70 bcs control rw yes unde?ned hps section 2 upload 74 chroma key range rw yes unde?ned 78 hps output and formats clip control rw yes unde?ned 7c debi_config rw yes unde?ned debi upload 80 debi_command rw yes unde?ned 84 debi_page rw yes unde?ned 88 debi_ad rw yes unde?ned 8c iictfr rw yes unde?ned i 2 c-bus upload 90 iic_sta rw yes 000004xx 94 basea1_in rw read unde?ned immediate write access 98 prota1_in rw read unde?ned 9c pagea1_in rw read unde?ned a0 basea1_out rw read unde?ned a4 prota1_out rw read unde?ned a8 pagea1_out rw read unde?ned ac basea2_in rw read unde?ned b0 prota2_in rw read unde?ned b4 pagea2_in rw read unde?ned b8 basea2_out rw read unde?ned bc prota2_out rw read unde?ned c0 pagea2_out rw read unde?ned c4 rps_page0 rw read unde?ned c8 rps_page1 rw read unde?ned cc rps_thresh0 rw read unde?ned d0 rps_thresh1 rw read unde?ned d4 rps_tov0 rw read unde?ned d8 rps_tov1 rw read unde?ned dc ier rw read unde?ned e0 gpio_ctrl rw read unde?ned e4 ec1ssr rw read unde?ned e8 ec2ssr rw read unde?ned ec ect1r rw read unde?ned f0 ect2r rw read unde?ned immediate write access f4 acon1 rw read unde?ned f8 acon2 rw read unde?ned offset (hex) name type ram read value after reset corresponding upload bit
1998 apr 09 131 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a fc mc1 rw no 00000100 immediate access 100 mc2 rw no 0000077f 104 rps_addr0 rw no 00000000 108 rps_addr1 rw no 00000000 10c isr rw no 00000000 110 psr r no unde?ned - 114 ssr r no unde?ned 118 ec1r r no 00000000 11c ec2r r no 00000000 120 pci_vdp1 r no 00000000 124 pci_vdp2 r no 00000000 128 pci_vdp3 r no 00000000 12c pci_adp1 r no 00000000 130 pci_adp2 r no 00000000 134 pci_adp3 r no 00000000 138 pci_adp4 r no 00000000 13c pci_ddp r no 00000000 140 level_rep r no 00000000 144 fb_buffer1 rw no 00000000 immediate access 148 fb_buffer2 rw no 00000000 180-1bc audio time slot registers 1 w no no read back 1c0-1fc audio time slot registers 2 w no no read back offset (hex) name type ram read value after reset corresponding upload bit 8 boundary scan test the saa7146a has built-in logic and 5 dedicated pins to support boundary scan testing which allows board testing without special hardware (nails). the saa7146a follows the ieee std. 1149.1 - standard test access port and boundary-scan architecture set by the joint test action group (jtag) chaired by philips. the 5 special pins are test mode select (tms), test clock (tck), test reset ( trst), test data input (tdi) and test data output (tdo). the built-in self test (bst) functions bypass, extest, sample, clamp and idcode are all supported (see table 116). details about the jtag bst-test can be found in specification ieee std. 1149.1 - standard test access port and boundary-scan architecture . a file containing the detailed boundary scan description language (bsdl) description of the saa7146a is available on request.
1998 apr 09 132 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a table 116 bst instructions supported by the saa7146a instruction description bypass this mandatory instruction provides a minimum length serial path (1-bit) between tdi and tdo when no test operation of the component is required extest this mandatory instruction allows testing of off-chip circuitry and board level interconnections sample this mandatory instruction can be used to take a sample of the inputs during normal operation of the component. it can also be used to preload data values into the latched outputs of the boundary scan register clamp this optional instruction is useful for testing when not all ics have bst. this instruction addresses the bypass register while the boundary scan register is in external test mode idcode this optional instruction will provide information on the components manufacturer, part number and version number 8.1 initialization of boundary scan circuit the test access port (tap) controller of an ic should be in the reset state (test_logic_reset) when the ic is in functional mode. this reset state also forces the instruction register into a functional instruction such as idcode or bypass. to solve the power-up reset, the standard specifies that the tap controller will be forced asynchronously to the test_logic_reset state by setting the trst pin low. 8.2 device identi?cation codes a device identification register is specified in ieee std. 1149.1 - standard test access port and boundary-scan architecture . it is a 32-bit register which contains fields for the specification of the ic manufacturer, the ic part number and the ic version number. its biggest advantage is the possibility to check for the correct ics mounted after production and determination of the version number of ics during field service. when the idcode instruction is loaded into the bst instruction register, the identification register will be connected between tdi and tdo of the ic. the identification register will load a component specific code during the capture_data_register state of the tap controller and this code can subsequently be shifted out. at board level this code can be used to verify component manufacturer, type and version number. the device identification register contains 32 bits, numbered from 31 to 0, where bit 31 is the most significant bit (nearest to tdi) and bit 0 is the least significant bit (nearest to tdo); see fig.46. fig.46 32 bits of identification code. handbook, full pagewidth mbh751 0000 4 bits version code 16 bit part number 11 bit manufacturer indentification 0111000101000110 00000010101 1 27 28 31 msb lsb 11 12 0 tdo 1 tdi
1998 apr 09 133 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 9 electrical operating conditions operating time: the circuit is designed to be able to operate continuously backup: no backup capability (standby) will be provided internally handling: inputs and outputs are protected against electrostatic discharge in normal handling. however, to be totally safe, it is desirable to take normal handling precautions appropriate to handling mos devices. 10 characteristics v ddd = 3.3 v for the internal core and for the i/o pad section. t amb = 0 to 70 c; unless otherwise speci?ed. symbol parameter conditions min. typ. max. unit supply v ddd digital supply voltage 3.0 3.3 3.6 v i ddd digital supply current video overlay rgb mode - 400 - ma data, clock and control inputs v il low-level input voltage clocks - 0.5 - +0.6 v other outputs - 0.5 - +0.8 v v ih high-level input voltage clocks 2.4 - 5.5 v other inputs 2.0 - 5.5 v i li input leakage current v il =0v -- 1 m a c i input capacitance -- 10 pf data, clock and control outputs; note 1 v ol low-level output voltage clocks 0 - 0.6 v other outputs; note 2 0 - 0.6 v v oh high-level output voltage clocks 2.6 - v ddd v other outputs; note 2 2.4 - v ddd v i 2 c-bus, sda and scl (pins 176 and 175) v il low-level input voltage (v ddi2c related input levels) note 3 - 0.5 - +0.3v ddi2c v v ih high-level input voltage (v ddi2c related input levels) note 3 0.7v ddi2c - v ddi2c + 0,5 v v hys hysteresis of schmitt trigger inputs (v ddi2c related input levels) note 3 0.05v ddi2c -- v v ol1 low-level output voltage (open-drain or open-collector) at 3 ma sink current 0 - 0.4 v ol2 low-level output voltage (open-drain or open-collector) at 6 ma sink current 0 - 0.6
1998 apr 09 134 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a t o(f) output fall time from v ihmin to v ilmax with a bus capacitance from 10 to 400 pf note 4 v up to 3 ma sink current at v ol1 20 + 0.1c b - 250 up to 3 ma sink current at v ol2 20 + 0.1c b - 250 i i input current each i/o pin with an input voltage between 0.4 and 0.9v ddi2cmax note 3 - 10 (5) - +10 (5) m a c i capacitance for each i/o pin -- 10 pf clock input timing (llc_a and llc_b); see fig.47 t llc_a , t llc_b cycle time 31 - 45 ns d duty factor t llch /t llc 40 50 60 % t r rise time -- 5ns t f fall time -- 6ns data and control input timing; see fig.47 t su set-up time 6 -- ns t hd hold time 3 -- ns clock output timing (llc_a, llc_b); see fig.47 c l output load capacitance 15 - 40 pf t llc_a , t llc_b cycle time 31 - 45 ns d duty factor t llch /t llc 40 50 60 % t r rise time 0.6 to 2.6 v -- 5ns t f fall time 2.6 to 0.6 v -- 5ns data and control output timing; see fig.47 c l load capacitance 15 - 40 pf t oh output hold time c l =15pf 4 -- ns t pd propagation delay from positive edge of llc_a, llc_b c l =40pf -- 25 ns pci i/o signals dc specification v ih high-level input voltage 2.0 - 5.75 v v il low-level input voltage - 0.5 - +0.8 v i lih high-level input leakage current v i = 2.7 v; note 1 -- 70 m a i lil low-level input leakage current v i = 0.5 v; note 1 --- 70 m a v oh high-level output voltage i o = - 2 ma 2.4 -- v v ol low-level output voltage i o = 3 and 6 ma; note 6 -- 0.55 v symbol parameter conditions min. typ. max. unit
1998 apr 09 135 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a c i input pin capacitance -- 10 pf c clk clk pin capacitance 5 - 12 pf c idsel idsel pin capacitance note 7 -- 8pf ac specification i oh switching current high 0 < v o 1.4; note 8 - 44 -- ma 1.4 < v o < 2.4; note 8 -- ma 3.1 < v o 2.2 v; note 8 95 -- ma 2.2 > v o > 0.55; note 8 v o /0.023 -- ma 0.71 > v o >0; note 8 -- note 10 test point v o = 0.71 v; notes 9 and 10 -- 206 ma t slew(r) output rise slew rate 0.4 to 2.4 v; note 11 1 - 5 v/ns t slew(f) output fall slew rate 2.4 to 0.4 v; note 11 1 - 5 v/ns timing parameters t val clk to signal valid delay (bussed signals) see note 12 and fig.48 2 - 11 ns t val(ptp) clk to signal valid delay (point-to-point) see note 12 and fig.48 2 - 12 ns t on ?oat to active delay see note 13 and fig.48 2 -- ns t off active to ?oat delay see note 13 and fig.48 -- 28 ns t su input set-up time to clk (bussed signal) see note 12 and fig.48 7 -- ns t su(ptp) input set-up time to clk (point-to-point) see note 12 and fig.48 10, 12 -- ns t h input hold time from clk see fig.48 0 -- ns t rst(clk) reset active time after clk stable note 14 100 -- m s t rst(off) reset active to output ?oat delay notes 13, 14 and 15 -- 40 ns symbol parameter conditions min. typ. max. unit 44 C v o 1.4 C () 0.024 --------------------------- +
1998 apr 09 136 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a notes 1. input leakage currents include high-impedance output leakage for all bidirectional buffer with 3-state outputs. 2. levels measured with load circuit: 1.2 k w at 3 v (ttl load) and c l =40pf. 3. voltage of the v ddi2c sense pin is defined as v ddi2c (4.75 : 5.0 : 5.25) (min. : typ. : max.) for 5 v i 2 c-bus devices and v ddi2c (3.0 : 3.3 : 3.6) (min. : typ. : max.) for 3 v i 2 c-bus devices. 4. c b = capacitance of one bus line measured in pf. 5. i/o pins of fast-mode devices must not obstruct the sda and scl lines if v ddi2c is switched off. 6. frame#, trdy#, irdy#, devsel# and stop#. 7. lower capacitance on this input only pin allows for non-resistive coupling to ad(xx). 8. refer to the v/i curves in pci specification. switching current high specifications are not relevant to inta#, which are open-drain outputs. 9. i oh = 11.9 (v o - 5.25) (v o + 2.45) for v ddd >v o > 3.1 v. 10. i ol = 78.5 v o (4.4 - v o ) for 0v 1998 apr 09 137 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a fig.47 clock/data timing. handbook, full pagewidth mgg279 clock input lcc_(a, b) data and control inputs data and control outputs input pxq_(a, b) clock output llc_(a, b) t llc t llch t f t r t su t hd t su t hd t oh t pd t llch t llcl t f t r 2.4 v 1.5 v 0.6 v 2.0 v 0.8 v 2.0 v 0.8 v 2.4 v 0.6 v 2.6 v 1.5 v 0.6 v not valid
1998 apr 09 138 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a fig.48 pci i/o timing. handbook, full pagewidth mgg280 t val t on t su t h t off 1.5 v 1.5 v 1.5 v 1.5 v 2.4 v 0.4 v 0.4 v 2.4 v clk output delay 3-state output input input valid
1998 apr 09 139 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 11 application example fig.49 application diagram. handbook, full pagewidth mhb043 analog audio analog audio analog video ntsc, pal analog video ntsc, pal antenna saa7360/66 i/o yuv, 2 d1 i 2 s i 2 c-bus saa7350/51 saa7111a front end decoder mpeg, m-jpeg codec saa7146a pci local bus saa7185b encoder philips tuner
1998 apr 09 140 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 12 package outlines unit a 1 a 2 a 3 b p ce (1) (1) (1) eh e ll p z y w v q references outline version european projection issue date iec jedec eiaj mm 0.40 0.25 3.70 3.15 0.25 0.40 0.25 0.23 0.13 28.1 27.9 0.65 0.3 1.95 32.2 31.6 1.5 1.1 8 0 o o 0.15 0.1 dimensions (mm are the original dimensions) note 1. plastic or metal protrusions of 0.25 mm maximum per side are not included. 1.1 0.7 sot322-1 mo112dd1 95-02-04 97-08-04 d (1) 28.1 27.9 h d 32.2 31.6 e z 1.5 1.1 d pin 1 index b p e q e a 1 a l p detail x l (a ) 3 b 40 c d h b p e h a 2 v m b d z d a z e e v m a x 1 160 121 120 81 80 41 y w m w m 0 5 10 mm scale sot322-1 160 leads (lead length 1.95 mm); body 28 x 28 x 3.4 mm; high stand-off height qfp160: plastic quad flat package; a max. 3.95
1998 apr 09 141 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a unit a 1 a 2 a 3 b p ce (1) eh e ll p z y w v q references outline version european projection issue date iec jedec eiaj mm 0.40 0.25 3.70 3.15 0.25 0.25 0.13 0.23 0.13 28.1 27.9 0.5 30.9 30.3 1.45 1.05 8 0 o o 0.1 0.1 1.3 0.075 dimensions (mm are the original dimensions) note 1. plastic or metal protrusions of 0.25 mm maximum per side are not included. 0.70 0.45 sot316-1 97-04-08 97-08-01 d (1) (1) (1) 28.1 27.9 h d 30.9 30.3 e z 1.45 1.05 d pin 1 index b p e q e a 1 a l p detail x l (a ) 3 b 52 c d h b p e h a 2 v m b d z d a z e e v m a x 1 208 157 156 105 104 53 y w m w m 0 5 10 mm scale 208 leads (lead length 1.3 mm); body 28 x 28 x 3.4 mm sqfp208: plastic shrink quad flat package; sot316-1 a max. 4.10
1998 apr 09 142 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 13 soldering 13.1 introduction there is no soldering method that is ideal for all ic packages. wave soldering is often preferred when through-hole and surface mounted components are mixed on one printed-circuit board. however, wave soldering is not always suitable for surface mounted ics, or for printed-circuits with high population densities. in these situations reflow soldering is often used. this text gives a very brief insight to a complex technology. a more in-depth account of soldering ics can be found in our ic package databook (order code 9398 652 90011). 13.2 re?ow soldering reflow soldering techniques are suitable for all qfp and sqfp packages. the choice of heating method may be influenced by larger plastic qfp packages (44 leads, or more). if infrared or vapour phase heating is used and the large packages are not absolutely dry (less than 0.1% moisture content by weight), vaporization of the small amount of moisture in them can cause cracking of the plastic body. for more information, refer to the drypack chapter in our quality reference handbook (order code 9397 750 00192). reflow soldering requires solder paste (a suspension of fine solder particles, flux and binding agent) to be applied to the printed-circuit board by screen printing, stencilling or pressure-syringe dispensing before package placement. several methods exist for reflowing; for example, infrared/convection heating in a conveyor type oven. throughput times (preheating, soldering and cooling) vary between 50 and 300 seconds depending on heating method. typical reflow peak temperatures range from 215 to 250 c. 13.3 wave soldering wave soldering is not recommended for qfp packages and is not suitable for sqfp packages. this is because of the likelihood of solder bridging due to closely-spaced leads and the possibility of incomplete solder penetration in multi-lead devices. caution wave soldering is not applicable for all qfp packages with a pitch (e) equal or less than 0.5 mm. if wave soldering cannot be avoided, for qfp packages with a pitch (e) larger than 0.5 mm, the following conditions must be observed: a double-wave (a turbulent wave with high upward pressure followed by a smooth laminar wave) soldering technique should be used. the footprint must be at an angle of 45 to the board direction and must incorporate solder thieves downstream and at the side corners. during placement and before soldering, the package must be fixed with a droplet of adhesive. the adhesive can be applied by screen printing, pin transfer or syringe dispensing. the package can be soldered after the adhesive is cured. maximum permissible solder temperature is 260 c, and maximum duration of package immersion in solder is 10 seconds, if cooled to less than 150 c within 6 seconds. typical dwell time is 4 seconds at 250 c. a mildly-activated flux will eliminate the need for removal of corrosive residues in most applications. 13.4 repairing soldered joints fix the component by first soldering two diagonally- opposite end leads. use only a low voltage soldering iron (less than 24 v) applied to the flat part of the lead. contact time must be limited to 10 seconds at up to 300 c. when using a dedicated tool, all other leads can be soldered in one operation within 2 to 5 seconds between 270 and 320 c.
1998 apr 09 143 philips semiconductors product speci?cation multimedia bridge, high performance scaler and pci circuit (spci) saa7146a 14 definitions 15 life support applications these products are not designed for use in life support appliances, devices, or systems where malfunction of these products can reasonably be expected to result in personal injury. philips customers using or selling these products for use in such applications do so at their own risk and agree to fully indemnify philips for any damages resulting from such improper use or sale. 16 purchase of philips i 2 c components data sheet status objective speci?cation this data sheet contains target or goal speci?cations for product development. preliminary speci?cation this data sheet contains preliminary data; supplementary data may be published later. product speci?cation this data sheet contains ?nal product speci?cations. limiting values limiting values given are in accordance with the absolute maximum rating system (iec 134). stress above one or more of the limiting values may cause permanent damage to the device. these are stress ratings only and operation of the device at these or at any other conditions above those given in the characteristics sections of the speci?cation is not implied. exposure to limiting values for extended periods may affect device reliability. application information where application information is given, it is advisory and does not form part of the speci?cation. purchase of philips i 2 c components conveys a license under the philips i 2 c patent to use the components in the i 2 c system provided the system conforms to the i 2 c specification defined by philips. this specification can be ordered using the code 9398 393 40011.
internet: http://www.semiconductors.philips.com philips semiconductors C a worldwide company ? philips electronics n.v. 1998 sca59 all rights are reserved. reproduction in whole or in part is prohibited without the prior written consent of the copyright owne r. the information presented in this document does not form part of any quotation or contract, is believed to be accurate and reli able and may be changed without notice. no liability will be accepted by the publisher for any consequence of its use. publication thereof does not con vey nor imply any license under patent- or other industrial or intellectual property rights. middle east: see italy netherlands: postbus 90050, 5600 pb eindhoven, bldg. vb, tel. +31 40 27 82785, fax. +31 40 27 88399 new zealand: 2 wagener place, c.p.o. box 1041, auckland, tel. +64 9 849 4160, fax. +64 9 849 7811 norway: box 1, manglerud 0612, oslo, tel. +47 22 74 8000, fax. +47 22 74 8341 pakistan: see singapore philippines: philips semiconductors philippines inc., 106 valero st. salcedo village, p.o. box 2108 mcc, makati, metro manila, tel. +63 2 816 6380, fax. +63 2 817 3474 poland: ul. lukiska 10, pl 04-123 warszawa, tel. +48 22 612 2831, fax. +48 22 612 2327 portugal: see spain romania: see italy russia: philips russia, ul. usatcheva 35a, 119048 moscow, tel. +7 095 755 6918, fax. +7 095 755 6919 singapore: lorong 1, toa payoh, singapore 319762, tel. +65 350 2538, fax. +65 251 6500 slovakia: see austria slovenia: see italy south africa: s.a. philips pty ltd., 195-215 main road martindale, 2092 johannesburg, p.o. box 7430 johannesburg 2000, tel. +27 11 470 5911, fax. +27 11 470 5494 south america: al. vicente pinzon, 173, 6th floor, 04547-130 s?o paulo, sp, brazil, tel. +55 11 821 2333, fax. +55 11 821 2382 spain: balmes 22, 08007 barcelona, tel. +34 3 301 6312, fax. +34 3 301 4107 sweden: kottbygatan 7, akalla, s-16485 stockholm, tel. +46 8 5985 2000, fax. +46 8 5985 2745 switzerland: allmendstrasse 140, ch-8027 zrich, tel. +41 1 488 2741 fax. +41 1 488 3263 taiwan: philips semiconductors, 6f, no. 96, chien kuo n. rd., sec. 1, taipei, taiwan tel. +886 2 2134 2865, fax. +886 2 2134 2874 thailand: philips electronics (thailand) ltd., 209/2 sanpavuth-bangna road prakanong, bangkok 10260, tel. +66 2 745 4090, fax. +66 2 398 0793 turkey: talatpasa cad. no. 5, 80640 gltepe/istanbul, tel. +90 212 279 2770, fax. +90 212 282 6707 ukraine : philips ukraine, 4 patrice lumumba str., building b, floor 7, 252042 kiev, tel. +380 44 264 2776, fax. +380 44 268 0461 united kingdom: philips semiconductors ltd., 276 bath road, hayes, middlesex ub3 5bx, tel. +44 181 730 5000, fax. +44 181 754 8421 united states: 811 east arques avenue, sunnyvale, ca 94088-3409, tel. +1 800 234 7381 uruguay: see south america vietnam: see singapore yugoslavia: philips, trg n. pasica 5/v, 11000 beograd, tel. +381 11 625 344, fax.+381 11 635 777 for all other countries apply to: philips semiconductors, international marketing & sales communications, building be-p, p.o. box 218, 5600 md eindhoven, the netherlands, fax. +31 40 27 24825 argentina: see south america australia: 34 waterloo road, north ryde, nsw 2113, tel. +61 2 9805 4455, fax. +61 2 9805 4466 austria: computerstr. 6, a-1101 wien, p.o. box 213, tel. +43 160 1010, fax. +43 160 101 1210 belarus: hotel minsk business center, bld. 3, r. 1211, volodarski str. 6, 220050 minsk, tel. +375 172 200 733, fax. +375 172 200 773 belgium: see the netherlands brazil: see south america bulgaria: philips bulgaria ltd., energoproject, 15th floor, 51 james bourchier blvd., 1407 sofia, tel. +359 2 689 211, fax. +359 2 689 102 canada: philips semiconductors/components, tel. +1 800 234 7381 china/hong kong: 501 hong kong industrial technology centre, 72 tat chee avenue, kowloon tong, hong kong, tel. +852 2319 7888, fax. +852 2319 7700 colombia: see south america czech republic: see austria denmark: prags boulevard 80, pb 1919, dk-2300 copenhagen s, tel. +45 32 88 2636, fax. +45 31 57 0044 finland: sinikalliontie 3, fin-02630 espoo, tel. +358 9 615800, fax. +358 9 61580920 france: 51 rue carnot, bp317, 92156 suresnes cedex, tel. +33 1 40 99 6161, fax. +33 1 40 99 6427 germany: hammerbrookstra?e 69, d-20097 hamburg, tel. +49 40 23 53 60, fax. +49 40 23 536 300 greece: no. 15, 25th march street, gr 17778 tavros/athens, tel. +30 1 4894 339/239, fax. +30 1 4814 240 hungary: see austria india: philips india ltd, band box building, 2nd floor, 254-d, dr. annie besant road, worli, mumbai 400 025, tel. +91 22 493 8541, fax. +91 22 493 0966 indonesia: pt philips development corporation, semiconductors division, gedung philips, jl. buncit raya kav.99-100, jakarta 12510, tel. +62 21 794 0040 ext. 2501, fax. +62 21 794 0080 ireland: newstead, clonskeagh, dublin 14, tel. +353 1 7640 000, fax. +353 1 7640 200 israel: rapac electronics, 7 kehilat saloniki st, po box 18053, tel aviv 61180, tel. +972 3 645 0444, fax. +972 3 649 1007 italy: philips semiconductors, piazza iv novembre 3, 20124 milano, tel. +39 2 6752 2531, fax. +39 2 6752 2557 japan: philips bldg 13-37, kohnan 2-chome, minato-ku, tokyo 108, tel. +81 3 3740 5130, fax. +81 3 3740 5077 korea: philips house, 260-199 itaewon-dong, yongsan-ku, seoul, tel. +82 2 709 1412, fax. +82 2 709 1415 malaysia: no. 76 jalan universiti, 46200 petaling jaya, selangor, tel. +60 3 750 5214, fax. +60 3 757 4880 mexico: 5900 gateway east, suite 200, el paso, texas 79905, tel. +9-5 800 234 7381 printed in the netherlands 655102/00/01/pp144 date of release: 1998 apr 09 document order number: 9397 750 03115


▲Up To Search▲   

 
Price & Availability of SAA7146AH

All Rights Reserved © IC-ON-LINE 2003 - 2022  

[Add Bookmark] [Contact Us] [Link exchange] [Privacy policy]
Mirror Sites :  [www.datasheet.hk]   [www.maxim4u.com]  [www.ic-on-line.cn] [www.ic-on-line.com] [www.ic-on-line.net] [www.alldatasheet.com.cn] [www.gdcy.com]  [www.gdcy.net]


 . . . . .
  We use cookies to deliver the best possible web experience and assist with our advertising efforts. By continuing to use this site, you consent to the use of cookies. For more information on cookies, please take a look at our Privacy Policy. X